public class DocumentSorter extends UnaryExpression
operandEFFECTIVE_BOOLEAN_VALUE, EVALUATE_METHOD, ITEM_FEED_METHOD, ITERATE_METHOD, locationId, MAX_SEQUENCE_LENGTH, MAX_STRING_LENGTH, PROCESS_METHOD, staticProperties, UNBOUNDED_LOWER, UNBOUNDED_UPPER, WATCH_METHOD| Constructor and Description |
|---|
DocumentSorter(Expression base) |
| Modifier and Type | Method and Description |
|---|---|
int |
computeSpecialProperties()
Get the static properties of this expression (other than its type).
|
Expression |
copy()
Copy an expression.
|
boolean |
effectiveBooleanValue(XPathContext context)
Get the effective boolean value of the expression.
|
void |
explain(ExpressionPresenter out)
Diagnostic print of expression structure.
|
ItemOrderComparer |
getComparer() |
ExpressionCompiler |
getExpressionCompiler()
Return the compiler of the DocumentSorter expression
|
String |
getExpressionName()
Get a name identifying the kind of expression, in terms meaningful to a user.
|
protected OperandRole |
getOperandRole()
Get the usage (in terms of streamability analysis) of the single operand
|
protected StreamingAdjunct |
getStreamingAdjunct()
Get a class that supports streamed evaluation of this expression
|
SequenceIterator |
iterate(XPathContext context)
Return an Iterator to iterate over the values of a sequence.
|
Expression |
optimize(ExpressionVisitor visitor,
ContextItemStaticInfo contextItemType)
Perform optimisation of an expression and its subexpressions.
|
Expression |
promote(PromotionOffer offer,
Expression parent)
Promote this expression if possible
|
Expression |
simplify(ExpressionVisitor visitor)
Simplify an expression.
|
Pattern |
toPattern(Configuration config,
boolean is30)
Convert this expression to an equivalent XSLT pattern
|
Expression |
unordered(boolean retainAllNodes,
boolean forStreaming)
Replace this expression by a simpler expression that delivers the results without regard
to order.
|
computeCardinality, displayOperator, equals, getBaseExpression, getItemType, hashCode, operands, replaceOperand, toShortString, toString, typeCheckaddToPathMap, adoptChildExpression, checkForUpdatingSubexpressions, checkPermittedContents, clearStreamabilityData, computeDependencies, computeStaticProperties, doPromotion, dynamicError, evaluateAsString, evaluateItem, evaluatePendingUpdates, explain, getCardinality, getColumnNumber, getConfiguration, getConstructType, getContainer, getDependencies, getEvaluationMethod, getHostLanguage, getImplementationMethod, getIntegerBounds, getIntrinsicDependencies, getLineNumber, getLocationId, getObjectName, getPosture, getProperties, getProperty, getPublicId, getSlotsUsed, getSpecialProperties, getStreamability, getSweep, getSystemId, hasVariableBinding, identityHashCode, implementsStaticTypeCheck, isIdentical, isSubtreeExpression, isUpdatingExpression, isVacuousExpression, iterateEvents, makeStreamingAdjunct, markTailFunctionCalls, operandList, process, resetLocalStaticProperties, setContainer, setEvaluationMethod, setFiltered, setFlattened, setLocationId, setPostureAndSweep, staticTypeCheck, suppressValidation, toStreamingPattern, typeErrorpublic DocumentSorter(Expression base)
protected OperandRole getOperandRole()
UnaryExpressiongetOperandRole in class UnaryExpressionpublic String getExpressionName()
getExpressionName in class Expressionpublic ItemOrderComparer getComparer()
public Expression simplify(ExpressionVisitor visitor) throws XPathException
Expressionsimplify in class Expressionvisitor - an expression visitorXPathException - if an error is discovered during expression
rewritingpublic Expression optimize(ExpressionVisitor visitor, ContextItemStaticInfo contextItemType) throws XPathException
UnaryExpressionThis method is called after all references to functions and variables have been resolved to the declaration of the function or variable, and after all type checking has been done.
optimize in class UnaryExpressionvisitor - an expression visitorcontextItemType - the static type of "." at the point where this expression is invoked.
The parameter is set to null if it is known statically that the context item will be undefined.
If the type of the context item is not known statically, the argument is set to
Type.ITEM_TYPEXPathException - if an error is discovered during this phase
(typically a type error)public Expression unordered(boolean retainAllNodes, boolean forStreaming) throws XPathException
unordered in class ExpressionretainAllNodes - set to true if the result must contain exactly the same nodes as the
original; set to false if the result can eliminate (or introduce) duplicates.forStreaming - set to true if optimizing for streamingXPathException - if the rewrite failspublic int computeSpecialProperties()
UnaryExpressioncomputeSpecialProperties in class UnaryExpressionpublic Expression copy()
copy in class Expressionpublic Expression promote(PromotionOffer offer, Expression parent) throws XPathException
promote in class UnaryExpressionoffer - details of the offer, for example the offer to move
expressions that don't depend on the context to an outer level in
the containing expressionparent - the containing expression in the expression treeXPathException - if any error is detectedpublic Pattern toPattern(Configuration config, boolean is30) throws XPathException
toPattern in class Expressionconfig - the Saxon configurationis30 - true if this is XSLT 3.0XPathException - if conversion is not possiblepublic SequenceIterator iterate(XPathContext context) throws XPathException
Expressioniterate in class Expressioncontext - supplies the context for evaluationXPathException - if any dynamic error occurs evaluating the
expressionpublic boolean effectiveBooleanValue(XPathContext context) throws XPathException
ExpressioneffectiveBooleanValue in class Expressioncontext - The context in which the expression is to be evaluatedXPathException - if any dynamic error occurs evaluating the
expressionpublic ExpressionCompiler getExpressionCompiler()
getExpressionCompiler in class Expressionpublic void explain(ExpressionPresenter out)
explain in class UnaryExpressionout - the expression presenter used to display the structureprotected StreamingAdjunct getStreamingAdjunct()
getStreamingAdjunct in class ExpressionCopyright (c) 2004-2014 Saxonica Limited. All rights reserved.