Provides interfaces for DOM Level 2 Traversal. Refer to the Document Object Model (DOM) Level 2 Traversal and Range Specification, the Traversal module contains specialized interfaces dedicated to traversing the document structure.
Interface Summary Interface Description DocumentTraversal
DocumentTraversalcontains methods that create
TreeWalkersto traverse a node and its children in document order (depth first, pre-order traversal, which is equivalent to the order in which the start tags occur in the text representation of the document).
NodeFilterFilters are objects that know how to "filter out" nodes. NodeIterator
NodeIteratorsare used to step through a set of nodes, e.g.
TreeWalkerobjects are used to navigate a document tree or subtree using the view of the document defined by their
whatToShowflags and filter (if any).