public class Id extends Function
staticContext| Constructor and Description |
|---|
Id() |
| Modifier and Type | Method and Description |
|---|---|
Value |
evaluate(Context context)
Evaluate in a general context
|
NodeSetValue |
evaluateAsNodeSet(Context context)
Evaluate in a context where a node-set is required
|
int |
getDataType()
Determine the data type of the expression
|
int |
getDependencies()
Determine which aspects of the context the expression depends on.
|
java.lang.String |
getName()
Get the name of the function.
|
boolean |
isContextDocumentNodeSet()
Determine, in the case of an expression whose data type is Value.NODESET,
whether all the nodes in the node-set are guaranteed to come from the same
document as the context node.
|
Expression |
reduce(int dependencies,
Context context)
Remove specified dependencies.
|
Expression |
simplify()
Simplify and validate
|
addArgument, checkArgumentCount, display, getNumberOfArgumentscontainsReferences, enumerate, evaluateAsBoolean, evaluateAsNumber, evaluateAsString, getStaticContext, indent, make, outputStringValue, setStaticContext, usesCurrentpublic java.lang.String getName()
Functionpublic int getDataType()
getDataType in class Expressionpublic boolean isContextDocumentNodeSet()
isContextDocumentNodeSet in class Expressionpublic Expression simplify() throws XPathException
simplify in class ExpressionXPathExceptionpublic NodeSetValue evaluateAsNodeSet(Context context) throws XPathException
evaluateAsNodeSet in class Expressioncontext - The context in which the expression is to be evaluatedXPathException - when the expression does not return a nodeset.public Value evaluate(Context context) throws XPathException
evaluate in class Expressioncontext - The context in which the expression is to be evaluatedXPathExceptionpublic int getDependencies()
getDependencies in class Expressionpublic Expression reduce(int dependencies, Context context) throws XPathException
reduce in class Expressiondependencies - The dependencies to be removed, e.g. Context.VARIABLEScontext - The context to be used for the partial evaluationXPathException