Interface NodeFilter


public interface NodeFilter
Filter the nodes returned by an iterator, see ParentNode.iterator(NodeFilter), ParentNode.iterator(int, NodeFilter) and DOMDocument.createNodeIterator(Node, int, NodeFilter).

The acceptNode(Node) method determines which nodes are accepted to be returned by the iterator.

Based on the NodeFilter callback interface in DOM Level 4, but not identical.

  • Field Details

  • Method Details

    • acceptNode

      short acceptNode(Node node)
      Find whether the given node is to be returned (or not) by an iterator.
      Parameters:
      node - the node to filter.
      Returns:
      FILTER_ACCEPT, FILTER_SKIP_NODE or FILTER_SKIP_NODE_CHILD.