Class AnyGNode

java.lang.Object
net.sf.saxon.pattern.nodetest.AnyGNode
All Implemented Interfaces:
NodePredicate, NodeVectorMatchMaker

public class AnyGNode extends Object implements NodePredicate, NodeVectorMatchMaker
  • Field Details

  • Method Details

    • test

      public boolean test(GNode node)
      Specified by:
      test in interface NodePredicate
    • getMatcher

      public IntPredicate getMatcher(NodeVectorTree tree)
      Get a matching function that can be used to test whether numbered nodes in a TinyTree or DominoTree satisfy the node test. (Calling this matcher must give the same result as calling matchesNode(tree.getNode(nodeNr)), but it may well be faster).
      Specified by:
      getMatcher in interface NodeVectorMatchMaker
      Parameters:
      tree - the tree against which the returned function will operate
      Returns:
      an IntPredicate; the matches() method of this predicate takes a node number as input, and returns true if and only if the node identified by this node number matches the node predicate.