Qizx/Open v0.3

net.xfra.qizxopen.dm
Interface NodeTest

All Known Implementing Classes:
BaseNodeTest, DocumentTest, UnionNodeTest

public interface NodeTest

Tests a node on behalf of path-steps or type matching.


Method Summary
 boolean accepts(int kind, QName name)
           
 boolean accepts(Node node)
           
 int getNodeKind()
          Returns the node kind (Node.ELEMENT, Node.TEXT etc) or -1 if not simple.
 boolean needsNode()
           
 boolean staticallyCheckable()
          Returns true for simple node test (node kind only).
 

Method Detail

accepts

public boolean accepts(int kind,
                       QName name)
Returns:
true if node matched. A null name is always accepted.

accepts

public boolean accepts(Node node)
Returns:
true if node matched. Used for extended tests like DocumentTest.

needsNode

public boolean needsNode()
Returns:
true if the node itself is necessary for checking (not only the kind and name). Allows optimization (avoids building a Node just for testing). Returns true for extended tests like DocumentTest.

getNodeKind

public int getNodeKind()
Returns the node kind (Node.ELEMENT, Node.TEXT etc) or -1 if not simple.


staticallyCheckable

public boolean staticallyCheckable()
Returns true for simple node test (node kind only).


 Copyright Xavier FRANC 2003-2004