com.novell.xml.xpath
Class OrExpr
java.lang.Object
com.novell.xml.xpath.BinaryExpr
com.novell.xml.xpath.BooleanExpr
com.novell.xml.xpath.OrExpr
- All Implemented Interfaces:
- Expression
- public class OrExpr
- extends BooleanExpr
- implements Expression
This class implements the XPath 'OrExpr' functionality.
The evaluation causes the lhs and rhs expressions to be
evaluated and the results to be converted to Boolean.
The result is true if either expression evaluates to true.
This is a "short-circuit" or expression.
OrExpr
public OrExpr(Expression lhs,
Expression rhs)
- Construct a logical 'or' expression
- Parameters:
lhs
- The left-hand-side expressionrhs
- The right-hand-side-expression
toString
public String toString()
- Provide a readable description for debugging.
- Returns:
- String representation
evaluate
public ExpressionValue evaluate(Node contextNode,
ExpressionContext context)
throws XPathEvaluationException
- Evaluate the expression with repect to the passed context
- Specified by:
evaluate
in interface Expression
- Parameters:
contextNode
- context node for expression evaluationcontext
- expression context for expression evaluation
- Returns:
- result of evaluating expression
- Throws:
XPathEvaluationException