create_node_iterator method

create_node_iterator

Create a new NodeIterator over the subtree rooted at the specified node.

Returns

The newly created NodeIterator.

def create_node_iterator(self, root):
    ...
ParameterTypeDescription
rootNodenode which will be iterated together with its children.
The iterator is initially positioned just before this node. The
whatToShow flags and the filter, if any, are not
considered when setting this position. The root must not be
null.

Exceptions

ExceptionDescription
DOMExceptionNOT_SUPPORTED_ERR: Raised if the specified root is
null.

create_node_iterator

Create a new NodeIterator over the subtree rooted at the specified node.

Returns

The newly created NodeIterator.

def create_node_iterator(self, root, what_to_show):
    ...
ParameterTypeDescription
rootNodenode which will be iterated together with its children.
The iterator is initially positioned just before this node. The
whatToShow flags and the filter, if any, are not
considered when setting this position. The root must not be
null.
what_to_showintflag specifies which node types may appear in
the logical view of the tree presented by the iterator. See the
description of NodeFilter for the set of possible
SHOW_ values.These flags can be combined using
OR.

Exceptions

ExceptionDescription
DOMExceptionNOT_SUPPORTED_ERR: Raised if the specified root is
null.

create_node_iterator

Create a new NodeIterator over the subtree rooted at the specified node.

Returns

The newly created NodeIterator.

def create_node_iterator(self, root, what_to_show, filter):
    ...
ParameterTypeDescription
rootNodenode which will be iterated together with its children.
The iterator is initially positioned just before this node. The
whatToShow flags and the filter, if any, are not
considered when setting this position. The root must not be
null.
what_to_showintflag specifies which node types may appear in
the logical view of the tree presented by the iterator. See the
description of NodeFilter for the set of possible
SHOW_ values.These flags can be combined using
OR.
filterINodeFilterNodeFilter to be used with this
TreeWalker, or null to indicate no filter.

Exceptions

ExceptionDescription
DOMExceptionNOT_SUPPORTED_ERR: Raised if the specified root is
null.

See Also