public class SingletonComparison extends BinaryExpression implements ComparisonExpression
operand0, operand1, operator
locationId, staticProperties
EVALUATE_METHOD, ITERATE_METHOD, PROCESS_METHOD
Constructor and Description |
---|
SingletonComparison(Expression p1,
int operator,
Expression p2) |
Modifier and Type | Method and Description |
---|---|
int |
computeCardinality()
Determine the static cardinality.
|
boolean |
convertsUntypedToOther()
Determine whether untyped atomic values should be converted to the type of the other operand
|
protected java.lang.String |
displayOperator() |
boolean |
effectiveBooleanValue(XPathContext context)
Evaluate the expression in a boolean context
|
Item |
evaluateItem(XPathContext context)
Evaluate the expression in a given context
|
AtomicComparer |
getAtomicComparer()
Get the AtomicComparer used to compare atomic values.
|
ItemType |
getItemType(TypeHierarchy th)
Determine the data type of the expression
|
int |
getSingletonOperator()
Get the primitive (singleton) operator used: one of Token.FEQ, Token.FNE, Token.FLT, Token.FGT,
Token.FLE, Token.FGE
|
void |
setComparator(AtomicComparer comp,
XPathContext context) |
computeSpecialProperties, display, equals, getOperands, getOperator, hashCode, isAssociative, isCommutative, isInverse, iterateSubExpressions, optimize, promote, replaceSubExpression, simplify, typeCheck
adoptChildExpression, checkPermittedContents, computeDependencies, computeStaticProperties, doPromotion, dynamicError, evaluateAsString, getCardinality, getColumnNumber, getConstructType, getDependencies, getExecutable, getHostLanguage, getImplementationMethod, getInstructionInfo, getIntrinsicDependencies, getLineNumber, getLocationId, getLocationProvider, getParentExpression, getPublicId, getSlotsUsed, getSpecialProperties, getSystemId, hasBadParentPointer, iterate, markTailFunctionCalls, process, resetStaticProperties, setLocationId, setParentExpression, setParentExpression, suppressValidation, typeError
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
getOperands
public SingletonComparison(Expression p1, int operator, Expression p2)
public void setComparator(AtomicComparer comp, XPathContext context)
public AtomicComparer getAtomicComparer()
ComparisonExpression
getAtomicComparer
in interface ComparisonExpression
public int getSingletonOperator()
ComparisonExpression
getSingletonOperator
in interface ComparisonExpression
public boolean convertsUntypedToOther()
convertsUntypedToOther
in interface ComparisonExpression
public int computeCardinality()
computeCardinality
in class BinaryExpression
public ItemType getItemType(TypeHierarchy th)
getItemType
in interface Expression
th
- public Item evaluateItem(XPathContext context) throws XPathException
evaluateItem
in interface Expression
evaluateItem
in class ComputedExpression
context
- the given context for evaluationXPathException
- if any dynamic error occurs evaluating the
expressionpublic boolean effectiveBooleanValue(XPathContext context) throws XPathException
effectiveBooleanValue
in interface Expression
effectiveBooleanValue
in class ComputedExpression
context
- the given context for evaluationXPathException
- if any dynamic error occurs evaluating the
expressionprotected java.lang.String displayOperator()
displayOperator
in class BinaryExpression