net.sf.saxon.sort
public class TupleExpression extends Expression
Field Summary | |
---|---|
Expression[] | components |
int[] | evaluationModes |
Constructor Summary | |
---|---|
TupleExpression(int width) |
Method Summary | |
---|---|
int | computeCardinality()
Get the cardinality of the expression. |
Expression | copy()
Copy an expression. |
Item | evaluateItem(XPathContext context) |
void | explain(ExpressionPresenter out)
Diagnostic print of expression structure. |
Expression[] | getComponents()
Get the component expressions |
int | getIntrinsicDependencies() |
ItemType | getItemType(TypeHierarchy th) |
Iterator<Expression> | iterateSubExpressions() |
Expression | optimize(ExpressionVisitor visitor, ItemType contextItemType)
Perform optimisation of an expression and its subexpressions.
|
Expression | promote(PromotionOffer offer, Expression parent) |
boolean | replaceSubExpression(Expression original, Expression replacement)
Replace one subexpression by a replacement subexpression |
void | setExpression(int i, Expression exp)
Set the i'th component expression of the tuple |
Expression | simplify(ExpressionVisitor visitor) |
Expression | typeCheck(ExpressionVisitor visitor, ItemType contextItemType) |
Returns: the static cardinality - EXACTLY_ONE
Returns: the copy of the original expression
Returns: the component expressions, as an array
This 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.
Parameters: visitor an expression visitor contextItemType 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 ITEM_TYPE
Returns: the original expression, rewritten if appropriate to optimize execution
Throws: XPathException if an error is discovered during this phase (typically a type error)
Parameters: original the original subexpression replacement the replacement subexpression
Returns: true if the original subexpression is found
Parameters: i identifies the component to set exp the component expression