public class NodeTypePattern extends AbstractPattern
Modifier and Type | Field and Description |
---|---|
static int |
ANY |
static int |
NODE |
_child, _parent, log, XMLNS
Modifier and Type | Method and Description |
---|---|
AbstractPattern |
copyPosition()
Copies the node matching portion of the pattern, i.e.
|
static AbstractPattern |
create(AbstractPattern parent,
int nodeType) |
boolean |
equals(java.lang.Object b)
Returns true if the two patterns are equal.
|
java.lang.String |
getNodeName()
Returns the name of the matching node or '*' if many nodes match.
|
int |
getNodeType()
Returns the matching node type.
|
double |
getPriority()
The node-type priority is less than nodes.
|
boolean |
isStrictlyAscending()
Returns true if the pattern is strictly ascending.
|
boolean |
match(org.w3c.dom.Node node,
ExprEnvironment env)
Matches if the node type matches.
|
java.lang.String |
toString()
Returns the printable representation of the pattern.
|
copyAxis, count, createNodeIterator, findAny, firstNode, getParent, getPrefix, isAscending, isUnique, lastNode, nextNode, position, select, selectUnique, toPatternString
public static final int NODE
public static final int ANY
public static AbstractPattern create(AbstractPattern parent, int nodeType)
public double getPriority()
getPriority
in class AbstractPattern
public java.lang.String getNodeName()
The Xsl package uses this to speed template matching.
getNodeName
in class AbstractPattern
public int getNodeType()
public boolean isStrictlyAscending()
isStrictlyAscending
in class AbstractPattern
public boolean match(org.w3c.dom.Node node, ExprEnvironment env) throws XPathException
match
in class AbstractPattern
node
- the current nodeenv
- the variable environmentXPathException
public AbstractPattern copyPosition()
copyPosition
in class AbstractPattern
public boolean equals(java.lang.Object b)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object