public class Assign extends Instruction implements BindingReference
EFFECTIVE_BOOLEAN_VALUE, EVALUATE_METHOD, EVENT_FEED_METHOD, INHERITED_CONTEXT, INSPECTION_CONTEXT, ITEM_FEED_METHOD, ITERATE_METHOD, locationId, MAX_SEQUENCE_LENGTH, MAX_STRING_LENGTH, NAVIGATION_CONTEXT, NODE_VALUE_CONTEXT, PROCESS_METHOD, PUSH_SELECTION, staticProperties, UNBOUNDED_LOWER, UNBOUNDED_UPPER, W3C_CONSUMING, W3C_FREE_RANGING, W3C_GROUP_CONSUMING, W3C_MOTIONLESS, WATCH_METHOD
Constructor and Description |
---|
Assign() |
Modifier and Type | Method and Description |
---|---|
Expression |
copy()
Copy an expression.
|
void |
explain(ExpressionPresenter out)
Diagnostic print of expression structure.
|
void |
fixup(Binding binding)
Fix up this binding reference to a binding
|
ExpressionCompiler |
getExpressionCompiler()
Return the compiler of the Assign expression
|
int |
getInstructionNameCode()
Get the name of this instruction for diagnostic and tracing purposes
|
int |
getIntrinsicDependencies()
Determine the intrinsic dependencies of an expression, that is, those which are not derived
from the dependencies of its subexpressions.
|
Iterator<Expression> |
iterateSubExpressions()
Get the immediate sub-expressions of this expression.
|
TailCall |
processLeavingTail(XPathContext context)
ProcessLeavingTail: called to do the real work of this instruction.
|
Expression |
promote(PromotionOffer offer,
Expression parent)
Offer promotion for this subexpression.
|
protected void |
promoteInst(PromotionOffer offer)
Handle promotion offers, that is, non-local tree rewrites.
|
void |
setSelectExpression(Expression select) |
void |
setStaticType(SequenceType type,
GroundedValue constantValue,
int properties)
Fix up the static type of this variable reference; optionally, supply a constant value for
the variable.
|
Expression |
simplify(ExpressionVisitor visitor)
Simplify an expression.
|
Expression |
typeCheck(ExpressionVisitor visitor,
ExpressionVisitor.ContextItemType contextItemType)
Perform type checking of an expression and its subexpressions.
|
assembleParams, assembleTunnelParams, computeCardinality, computeSpecialProperties, createsNewNodes, dynamicError, evaluateAsString, evaluateItem, getConstructType, getExpressionName, getImplementationMethod, getInstructionName, getItemType, getIteratorFromProcessMethod, getSourceLocator, isXSLT, iterate, process
addToPathMap, adoptChildExpression, checkForUpdatingSubexpressions, checkPermittedContents, computeDependencies, computeStaticProperties, doPromotion, dynamicError, effectiveBooleanValue, evaluatePendingUpdates, explain, getCardinality, getColumnNumber, getColumnNumber, getContainer, getDependencies, getEvaluationMethod, getExecutable, getHostLanguage, getIntegerBounds, getLineNumber, getLineNumber, getLocationId, getLocationProvider, getObjectName, getProperties, getProperty, getPublicId, getSlotsUsed, getSpecialProperties, getStreamability, getStreamingAdjunct, getSystemId, getSystemId, hasVariableBinding, implementsStaticTypeCheck, isSubtreeExpression, isUpdatingExpression, isVacuousExpression, iterateEvents, iterateSubExpressionInfo, markTailFunctionCalls, optimize, replaceSubExpression, resetLocalStaticProperties, setContainer, setEvaluationMethod, setFiltered, setFlattened, setLocationId, staticTypeCheck, suppressValidation, toPattern, toStreamingPattern, toString, typeError
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getColumnNumber, getLineNumber, getPublicId, getSystemId
public void setStaticType(SequenceType type, GroundedValue constantValue, int properties)
BindingReference
setStaticType
in interface BindingReference
type
- The static type of the variable reference, typically either the declared type
of the variable, or the static type of the expression to which the variable is boundconstantValue
- if non-null, indicates that the value of the variable is known at compile
time, and supplies the valueproperties
- static properties of the expression to which the variable is boundpublic void setSelectExpression(Expression select)
public void fixup(Binding binding)
BindingReference
fixup
in interface BindingReference
binding
- the Binding to which the variable referspublic int getIntrinsicDependencies()
Expression
getIntrinsicDependencies
in class Expression
public Expression simplify(ExpressionVisitor visitor) throws XPathException
simplify
in class Instruction
visitor
- an expression visitorXPathException
- if an error is discovered during expression
rewritingpublic Expression typeCheck(ExpressionVisitor visitor, ExpressionVisitor.ContextItemType contextItemType) throws XPathException
typeCheck
in class Expression
visitor
- 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_TYPE
XPathException
- if an error is discovered during this phase
(typically a type error)public Expression copy()
copy
in class Expression
public Iterator<Expression> iterateSubExpressions()
Expression
iterateSubExpressions
in class Expression
public Expression promote(PromotionOffer offer, Expression parent) throws XPathException
promote
in class Instruction
offer
- 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 parent expression of the expression to be promotedXPathException
- if any error is detectedprotected void promoteInst(PromotionOffer offer) throws XPathException
promoteInst
in class Instruction
offer
- The type of rewrite being offeredXPathException
- if an error occurspublic int getInstructionNameCode()
getInstructionNameCode
in class Instruction
public TailCall processLeavingTail(XPathContext context) throws XPathException
Instruction
processLeavingTail
in interface TailCallReturner
processLeavingTail
in class Instruction
context
- The dynamic context of the transformation, giving access to the current node,
the current variables, etc.XPathException
- if a dynamic error occurs during the evaluation
of the instructionpublic ExpressionCompiler getExpressionCompiler()
getExpressionCompiler
in class Expression
public void explain(ExpressionPresenter out)
explain
in class Expression
out
- the expression presenter used to display the structureCopyright (c) 2004-2013 Saxonica Limited. All rights reserved.