public abstract class NodeTest extends Pattern
originalText, staticContext| Constructor and Description |
|---|
NodeTest() |
| Modifier and Type | Method and Description |
|---|---|
abstract boolean |
matches(NodeInfo node)
Test whether this node test is satisfied by a given node
|
boolean |
matches(NodeInfo node,
Context c)
Test whether this node test is satisfied by a given node, in a given Context
|
abstract boolean |
matches(short nodeType,
int fingerprint)
Test whether this node test is satisfied by a given node
|
getDefaultPriority, getFingerprint, getLineNumber, getNodeType, getStaticContext, getSystemId, make, setOriginalText, setStaticContext, simplify, toStringpublic abstract boolean matches(NodeInfo node)
public abstract boolean matches(short nodeType,
int fingerprint)
nodeType - The type of node to be matchedfingerprint - identifies the expanded name of the node to be matched.
The value should be -1 for a node with no name.public final boolean matches(NodeInfo node, Context c)
matches in class Patternnode - The NodeInfo representing the Element or other node to be tested against the Patternc - The context in which the match is to take place. Only relevant if the pattern
uses variables.