org.exolab.adaptx.xpath.expressions
Class UnionExpr
java.lang.Object
org.exolab.adaptx.xpath.expressions.UnionExpr
- MatchExpression, XPathExpression
public abstract class UnionExpr
extends java.lang.Object
An abstract class that represents an XPath Union expression
UnionExpr ::= PathExpr | (PathExpr '|' UnionExpr)
$Revision: 3734 $ $Date: 2003-05-13 09:55:04 +0200 (Tue, 13 May 2003) $BOOLEAN , ERROR , FILTER_EXPR , LOCATION_PATH , NODE_TEST , NUMBER , PATH_EXPR , PRIMARY , STEP , STRING , UNION_EXPR |
getExprType
public final short getExprType()
Returns the type of Expr this Expr represents
- getExprType in interface XPathExpression
- the type of Expr this Expr represents
getMatchingExpr
public PathExpr getMatchingExpr(XPathNode node,
XPathContext context)
throws XPathException
Retrieves the PathExpr that matches the given node. If more
than one PathExpr matches the given node, the most specific
PathExpr will be returned.
node
- the node to test for matching
- the matching PathExpr or null if none match
getPathExpr
public abstract PathExpr getPathExpr()
Returns the PathExpr of this UnionExpr. A UnionExpr
is defined by XPath 1.0 as:
UnionExpr ::= PathExpr | (PathExpr '|' UnionExpr)
- the PathExpr of this UnionExpr.
getUnionExpr
public abstract UnionExpr getUnionExpr()
Returns the UnionExpr that this UnionExpr is in union
with. A UnionExpr is defined by XPath 1.0 as:
UnionExpr ::= PathExpr | (PathExpr '|' UnionExpr)
- the UnionExpr that this UnionExpr is in union
with, or null if this is UnionExpr only contains
a PathExpr.
matches
public abstract boolean matches(XPathNode node,
XPathContext context)
throws XPathException
Determines if the given node is matched by this MatchExpr with
respect to the given context.
- matches in interface MatchExpression
node
- the node to determine a match forcontext
- the XPathContext
- true if the given node is matched by this MatchExpr