NodeIterator Class
https://dom.spec.whatwg.org/#interface-nodeiterator
public sealed class NodeIteratorProperties
| Name | Description |
|---|---|
| Filter | Gets the filter used to accept, reject or skip nodes, or null when there is none. |
| PointerBeforeReferenceNode | Gets a value indicating whether the iterator is positioned before the reference node. |
| ReferenceNode | Gets the node the iterator is currently positioned at. |
| Root | Gets the root node of the traversal. |
| WhatToShow | Gets the bit mask of the node types the iterator presents. |
Filter
NodeIterator.csGets the filter used to accept, reject or skip nodes, or null when there is none.
public INodeFilter? Filter { get; }PointerBeforeReferenceNode
NodeIterator.csGets a value indicating whether the iterator is positioned before the reference node.
public bool PointerBeforeReferenceNode { get; }ReferenceNode
NodeIterator.csGets the node the iterator is currently positioned at.
public Node ReferenceNode { get; }Root
NodeIterator.csGets the root node of the traversal.
public Node Root { get; }WhatToShow
NodeIterator.csGets the bit mask of the node types the iterator presents.
public uint WhatToShow { get; }Methods
| Name | Description |
|---|---|
| Detach() | Does nothing (https://dom.spec.whatwg.org/#dom-nodeiterator-detach). |
| NextNode() | Moves the iterator to the next accepted node and returns it, or null when there is none. |
| PreviousNode() | Moves the iterator to the previous accepted node and returns it, or null when there is none. |
Detach()
NodeIterator.csDoes nothing (https://dom.spec.whatwg.org/#dom-nodeiterator-detach).
public void Detach()NextNode()
NodeIterator.csMoves the iterator to the next accepted node and returns it, or null when there is none.
public Node? NextNode()PreviousNode()
NodeIterator.csMoves the iterator to the previous accepted node and returns it, or null when there is none.
public Node? PreviousNode()