net.sf.saxon.instruct

Class GlobalParam

Implemented Interfaces:
Container, Serializable, SourceLocator, Binding, EvaluableItem, InstructionInfoProvider, SequenceIterable, SourceLocator, TailCallReturner

public final class GlobalParam
extends GlobalVariable

The compiled form of a global xsl:param element in the stylesheet or an external variable declared in the prolog of a Query.
The xsl:param element in XSLT has mandatory attribute name and optional attribute select. It can also be specified as required="yes" or required="no". In standard XQuery external variables are always required, and no default value can be specified; but Saxon provides an extension pragma that allows a query to specify a default.

Field Summary

Fields inherited from class net.sf.saxon.instruct.GeneralVariable

evaluationMode, referenceCount, slotNumber, variableQName

Fields inherited from class net.sf.saxon.expr.Expression

EVALUATE_METHOD, ITERATE_METHOD, PROCESS_METHOD, locationId, staticProperties

Method Summary

ValueRepresentation
evaluateVariable(XPathContext context)
Evaluate the variable
int
getInstructionNameCode()
Get the name of this instruction for diagnostic and tracing purposes

Methods inherited from class net.sf.saxon.instruct.GlobalVariable

evaluateVariable, getExecutable, getHostLanguage, getInstructionInfo, getSelectValue, isGlobal, lookForCycles, processLeavingTail, setContainsLocals, setExecutable, setHostLanguage

Methods inherited from class net.sf.saxon.instruct.GeneralVariable

copy, evaluateItem, explain, getCardinality, getEvaluationMode, getInstructionNameCode, getItemType, getLocalSlotNumber, getRequiredType, getSelectExpression, getSelectValue, getSlotNumber, getVariableQName, init, isAssignable, isGlobal, isImplicitlyRequiredParam, isRequiredParam, isTunnelParam, iterate, iterateSubExpressions, optimize, promoteInst, replaceSubExpression, setAssignable, setImplicitlyRequiredParam, setReferenceCount, setRequiredParam, setRequiredType, setSelectExpression, setSlotNumber, setTunnel, setVariableQName, simplify, typeCheck

Methods inherited from class net.sf.saxon.instruct.Instruction

assembleParams, assembleTunnelParams, computeCardinality, computeSpecialProperties, createsNewNodes, dynamicError, evaluateAsString, evaluateItem, getImplementationMethod, getInstructionInfo, getInstructionNameCode, getItemType, getSourceLocator, isXSLT, iterate, process, processLeavingTail, promote, promoteInst, simplify

Methods inherited from class net.sf.saxon.expr.Expression

addToPathMap, adoptChildExpression, checkPermittedContents, computeCardinality, computeDependencies, computeSpecialProperties, computeStaticProperties, copy, display, doPromotion, dynamicError, effectiveBooleanValue, evaluateAsString, evaluateItem, explain, explain, findParentOf, getCardinality, getColumnNumber, getConstructType, getContainer, getDependencies, getExecutable, getHostLanguage, getImplementationMethod, getInstructionInfo, getIntrinsicDependencies, getItemType, getLineNumber, getLocationId, getLocationProvider, getPublicId, getSlotsUsed, getSpecialProperties, getSystemId, hasLoopingSubexpression, implementsStaticTypeCheck, iterate, iterateEvents, iterateSubExpressions, markTailFunctionCalls, optimize, process, promote, replaceSubExpression, resetLocalStaticProperties, setContainer, setFiltered, setFlattened, setLocationId, simplify, staticTypeCheck, suppressValidation, toString, typeCheck, typeError

Method Details

evaluateVariable

public ValueRepresentation evaluateVariable(XPathContext context)
            throws XPathException
Evaluate the variable
Specified by:
evaluateVariable in interface Binding
Overrides:
evaluateVariable in interface GlobalVariable

getInstructionNameCode

public int getInstructionNameCode()
Get the name of this instruction for diagnostic and tracing purposes
Overrides:
getInstructionNameCode in interface GeneralVariable