net.sf.saxon.expr
public class GeneralComparison extends BinaryExpression
Field Summary | |
---|---|
protected AtomicComparer | comparer |
protected int | singletonOperator |
Constructor Summary | |
---|---|
GeneralComparison(Expression p0, int op, Expression p1)
Create a relational expression identifying the two operands and the operator
|
Method Summary | |
---|---|
protected static boolean | compare(AtomicValue a1, int operator, AtomicValue a2, AtomicComparer comparer, XPathContext context)
Compare two atomic values |
int | computeCardinality()
Determine the static cardinality. |
protected String | displayOperator() |
boolean | effectiveBooleanValue(XPathContext context)
Evaluate the expression in a boolean context
|
Item | evaluateItem(XPathContext context)
Evaluate the expression in a given context
|
protected GeneralComparison | getInverseComparison() |
ItemType | getItemType(TypeHierarchy th)
Determine the data type of the expression
|
Expression | optimize(Optimizer opt, StaticContext env, ItemType contextItemType)
Optimize the expression
|
Expression | typeCheck(StaticContext env, ItemType contextItemType)
Type-check the expression
|
Parameters: p0 the left-hand operand op the operator, as a token returned by the Tokenizer (e.g. Token.LT) p1 the right-hand operand
Parameters: context the given context for evaluation
Returns: a boolean representing the result of the numeric comparison of the two operands
Parameters: context the given context for evaluation
Returns: a BooleanValue representing the result of the numeric comparison of the two operands
Parameters: th
Returns: Type.BOOLEAN
Returns: the checked expression
Returns: the checked expression