|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Object | +--org.exolab.adaptx.xpath.expressions.PathExpr
An abstract class representing an XPath Location Path expression.
| Field Summary |
|---|
| Fields inherited from interface org.exolab.adaptx.xpath.XPathExpression |
|---|
BOOLEAN, ERROR, FILTER_EXPR, LOCATION_PATH, NODE_TEST, NUMBER, PATH_EXPR, PRIMARY, STEP, STRING, UNION_EXPR |
| Constructor Summary | |
|---|---|
PathExpr()
|
|
| Method Summary | |
|---|---|
abstract XPathResult |
evaluate(XPathContext context)
Evaluates the expression and returns the XPath result. |
abstract double |
getDefaultPriority()
Determines the priority of a PatternExpr as follows: |
short |
getExprType()
Returns the XPathExpression type |
abstract PathComponent |
getPathComponent()
Returns the PathComponent for the this PathExpr, either a FilterExpr or LocationStep. |
abstract PathExpr |
getSubPath()
|
abstract boolean |
isAbsolute()
Returns true if this PathExpr is an absolute expression, otherwise false (ie. |
abstract boolean |
matches(XPathNode node,
XPathContext context)
Determines if the given node is matched by this MatchExpr with respect to the given context. |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.exolab.adaptx.xpath.XPathExpression |
|---|
toString |
| Constructor Detail |
public PathExpr()
| Method Detail |
public abstract XPathResult evaluate(XPathContext context)
throws XPathException
evaluate in interface XPathExpressioncontext - The XPathContext to use during evaluation.
XPathException - if an error occured while
evaluating this expression.public final short getExprType()
getExprType in interface XPathExpressionXPathExpressionpublic abstract PathComponent getPathComponent()
public abstract PathExpr getSubPath()
public abstract double getDefaultPriority()
From the 19991116 XSLT 1.0 Recommendation:
+ If the pattern has the form of a QName preceded by a
ChildOrAttributeAxisSpecifier or has the form
processing-instruction(Literal) then the priority is 0.
+ If the pattern has the form NCName:* preceded by a
ChildOrAttributeAxisSpecifier, then the priority is -0.25
+ Otherwise if the pattern consists of just a NodeTest
preceded by a ChildOrAttributeAxisSpecifier then the
priority is -0.5
+ Otherwise the priority is 0.5
public abstract boolean isAbsolute()
public abstract boolean matches(XPathNode node,
XPathContext context)
throws XPathException
matches in interface MatchExpressionnode - the node to determine a match forcontext - the XPathContext
XPathException - when an error occurs during
evaluation
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||