com.novell.xml.xpath
Class BrokenNotEqualsExpr
java.lang.Object
com.novell.xml.xpath.BinaryExpr
com.novell.xml.xpath.BooleanExpr
com.novell.xml.xpath.ComparisonExpr
com.novell.xml.xpath.EqualsExpr
com.novell.xml.xpath.BrokenNotEqualsExpr
- All Implemented Interfaces:
- Expression
- public class BrokenNotEqualsExpr
- extends EqualsExpr
- implements Expression
This class implements the XPath 'EqualityExpr' functionality. However,
this class behaves incorrectly relative to a != expression where only
one of the operands is a node-set. It exists solely for a
backwards-compatible mode for DirXML.
The class that behaves correctly according to the XPath 1.0 spec is
NotEqualsExpr
.
The evaluation causes the lhs and rhs expressions to be
evaluated and the results compared.
The result is true if the two operands evaluate to unequal values
BrokenNotEqualsExpr
public BrokenNotEqualsExpr(Expression lhs,
Expression rhs)
- Construct an equality expression
- Parameters:
lhs
- The left-hand-side expressionrhs
- The right-hand-side-expression
toString
public String toString()
- Provide a readable description for debugging.
- Overrides:
toString
in class EqualsExpr
- 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
- Overrides:
evaluate
in class EqualsExpr
- Parameters:
contextNode
- context node for expression evaluationcontext
- expression context for expression evaluation
- Returns:
- result of evaluating expression
- Throws:
XPathEvaluationException