public class NegateExpression extends UnaryExpression
EFFECTIVE_BOOLEAN_VALUE, EVALUATE_METHOD, ITEM_FEED_METHOD, ITERATE_METHOD, MAX_SEQUENCE_LENGTH, MAX_STRING_LENGTH, PROCESS_METHOD, staticProperties, UNBOUNDED_LOWER, UNBOUNDED_UPPER, UPDATE_METHOD, WATCH_METHOD| Constructor and Description |
|---|
NegateExpression(Expression base)
Create a NegateExpression
|
| Modifier and Type | Method and Description |
|---|---|
Expression |
copy(RebindingMap rebindings)
Copy an expression.
|
protected java.lang.String |
displayOperator(Configuration config)
Give a string representation of the operator for use in diagnostics
|
NumericValue |
evaluateItem(XPathContext context)
Evaluate the expression.
|
void |
export(ExpressionPresenter out)
Diagnostic print of expression structure.
|
java.lang.String |
getExpressionName()
Get a name identifying the kind of expression, in terms meaningful to a user.
|
int |
getImplementationMethod()
An implementation of Expression must provide at least one of the methods evaluateItem(), iterate(), or process().
|
ItemType |
getItemType()
Determine the data type of the expression, if this is known statically
/*@NotNull
|
protected OperandRole |
getOperandRole()
Get the usage (in terms of streamability analysis) of the single operand
|
boolean |
isBackwardsCompatible()
Ask whether the expression is to be evaluated in XPath 1.0 compatibility mode
|
void |
setBackwardsCompatible(boolean compatible)
Set whether the expression is to be evaluated in XPath 1.0 compatibility mode
|
Expression |
typeCheck(ExpressionVisitor visitor,
ContextItemStaticInfo contextInfo)
Type-check the expression.
|
computeCardinality, computeHashCode, computeSpecialProperties, equals, getBaseExpression, getOperand, operands, optimize, setBaseExpression, toShortString, toStringaddToPathMap, adoptChildExpression, allowExtractingCommonSubexpressions, checkedOperands, checkForUpdatingSubexpressions, checkPermittedContents, computeDependencies, computeStaticProperties, dynamicError, effectiveBooleanValue, evaluateAsString, evaluatePendingUpdates, explain, getCardinality, getConfiguration, getConstructType, getCost, getDependencies, getEvaluationMethod, getExtraProperty, getIntegerBounds, getInterpretedExpression, getIntrinsicDependencies, getLocalRetainedStaticContext, getLocation, getNetCost, getObjectName, getPackageData, getParentExpression, getProperties, getProperty, getRetainedStaticContext, getScopingExpression, getSlotsUsed, getSpecialProperties, getStaticBaseURI, getStaticBaseURIString, getStaticType, getStaticUType, getStreamerName, hasCompatibleStaticContext, hashCode, hasVariableBinding, identityHashCode, implementsStaticTypeCheck, isCallOn, isCallOnSystemFunction, isIdentical, isInstruction, isLiftable, isMultiThreaded, isSameExpression, isStaticPropertiesKnown, isSubtreeExpression, isUpdatingExpression, isVacuousExpression, iterate, markTailFunctionCalls, operandList, operandSparseList, optimizeChildren, process, resetLocalStaticProperties, restoreParentPointers, setEvaluationMethod, setExtraProperty, setFiltered, setFlattened, setLocation, setParentExpression, setRetainedStaticContext, setRetainedStaticContextLocally, setRetainedStaticContextThoroughly, setStaticProperty, simplify, simplifyChildren, staticTypeCheck, suppressValidation, toPattern, typeCheckChildren, typeError, unordered, verifyParentPointers, verifyParentPointerspublic NegateExpression(Expression base)
base - the expression that computes the value whose sign is to be reversedpublic void setBackwardsCompatible(boolean compatible)
compatible - true if XPath 1.0 compatibility mode is enabledpublic boolean isBackwardsCompatible()
protected OperandRole getOperandRole()
UnaryExpressiongetOperandRole in class UnaryExpressionpublic Expression typeCheck(ExpressionVisitor visitor, ContextItemStaticInfo contextInfo) throws XPathException
UnaryExpressiontypeCheck in class UnaryExpressionvisitor - an expression visitorcontextInfo - Information available statically about the context item: whether it is (possibly)
absent; its static type; its streaming posture.XPathException - if an error is discovered during this phase
(typically a type error)public ItemType getItemType()
getItemType in class UnaryExpressionpublic int getImplementationMethod()
getImplementationMethod in class ExpressionExpression.ITERATE_METHOD or Expression.EVALUATE_METHOD or
Expression.PROCESS_METHODpublic NumericValue evaluateItem(XPathContext context) throws XPathException
evaluateItem in class Expressioncontext - The context in which the expression is to be evaluatedXPathException - if any dynamic error occurs evaluating the
expressionpublic Expression copy(RebindingMap rebindings)
copy in class Expressionrebindings - protected java.lang.String displayOperator(Configuration config)
UnaryExpressiondisplayOperator in class UnaryExpressionconfig - the Saxon configurationpublic java.lang.String getExpressionName()
getExpressionName in class Expressionpublic void export(ExpressionPresenter out) throws XPathException
UnaryExpressionexport in interface ExportAgentexport in class UnaryExpressionout - the expression presenter used to display the structureXPathException - if the export fails, for example if an expression is found that won't work
in the target environment.Copyright (c) 2004-2018 Saxonica Limited. All rights reserved.