Expand description
Types associated to nodes and in particular node walking.
Structs§
- Ancestors
- An iterator over an element and its ancestors, starting with the element
itself and following
Node::parentup to the root. - Children
- An iterator over the children of a node or the root of a tree, nodes and tokens in order.
- Inside
- An iterator that limits the walk to inside the node it started at, visiting
every node exactly once. This is constructed with
Walk::inside. - Node
- An interior node in the tree, one which was opened with
Builder::openor wrapped withBuilder::close_at. - Siblings
- An iterator over an element and its following siblings, nodes and tokens in order. Previous siblings are not included.
- Skip
Tokens - Wrapped around an iterator that excludes tokens, yielding only interior
Nodes. - Token
- A token in the tree, one which was added with
Builder::tokenor its variants. - Walk
- An iterator that walks over the entire tree in depth-first order, visiting every node and token exactly once.
- Walk
Events - A low-level iterator which walks the tree while emitting Event instances indicating how the structure is being navigated.
- With
Depths - An iterator that walks over the entire tree, visiting every node exactly
once and yielding each node together with its depth. This is constructed
with
Walk::with_depths.
Enums§
- Event
- An event indicating how a tree is being walked with
WalkEvents. - Node
OrToken - Either a node or a token.
Type Aliases§
- Element
- A node or a token in a tree.