public abstract class SingletonExpression extends NodeSetExpression
staticContext| Constructor and Description |
|---|
SingletonExpression() |
| Modifier and Type | Method and Description |
|---|---|
NodeEnumeration |
enumerate(Context context,
boolean sort)
Evaluate the expression in a given context to return a Node enumeration
|
boolean |
evaluateAsBoolean(Context context)
Evaluate as a boolean.
|
NodeSetValue |
evaluateAsNodeSet(Context context)
Evaluate an expression as a NodeSet.
|
java.lang.String |
evaluateAsString(Context context)
Evaluate as a string.
|
abstract NodeInfo |
getNode(Context context)
Get the single node to which this expression refers
|
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.
|
NodeInfo |
selectFirst(Context context)
Return the first node selected by this Expression when evaluated in the current context
|
evaluate, getDataType, outputStringValuecontainsReferences, display, evaluateAsNumber, getDependencies, getStaticContext, indent, make, reduce, setStaticContext, simplify, usesCurrentpublic boolean isContextDocumentNodeSet()
isContextDocumentNodeSet in class Expressionpublic abstract NodeInfo getNode(Context context) throws XPathException
XPathExceptionpublic NodeInfo selectFirst(Context context) throws XPathException
selectFirst in class NodeSetExpressioncontext - The context for the evaluationXPathExceptionpublic NodeEnumeration enumerate(Context context, boolean sort) throws XPathException
enumerate in class NodeSetExpressioncontext - the evaluation contextsort - Indicates result must be in document orderXPathException - when the expression does not return a nodeset.public NodeSetValue evaluateAsNodeSet(Context context) throws XPathException
evaluateAsNodeSet in class NodeSetExpressioncontext - The context in which the expression is to be evaluatedXPathException - when the expression does not return a nodeset.public java.lang.String evaluateAsString(Context context) throws XPathException
evaluateAsString in class NodeSetExpressioncontext - The context in which the expression is to be evaluatedXPathExceptionpublic boolean evaluateAsBoolean(Context context) throws XPathException
evaluateAsBoolean in class NodeSetExpressioncontext - The context in which the expression is to be evaluatedXPathException