|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.sf.saxon.value.Value
net.sf.saxon.value.SingletonNode
A value that is a sequence containing zero or one nodes
| Field Summary | |
protected NodeInfo |
node
|
| Fields inherited from class net.sf.saxon.value.Value |
EMPTY_CLASS_ARRAY |
| Fields inherited from interface net.sf.saxon.expr.Expression |
EVALUATE_METHOD, ITERATE_METHOD, PROCESS_METHOD |
| Fields inherited from interface net.sf.saxon.om.ValueRepresentation |
EMPTY_VALUE_ARRAY |
| Constructor Summary | |
SingletonNode(NodeInfo node)
Create a node-set containing zero or one nodes |
|
| Method Summary | |
java.lang.Object |
convertToJava(java.lang.Class target,
XPathContext context)
Convert to Java object (for passing to external functions) |
void |
display(int depth,
NamePool pool,
java.io.PrintStream out)
Diagnostic display |
boolean |
effectiveBooleanValue(XPathContext context)
Get the effective boolean value |
java.lang.String |
evaluateAsString(XPathContext context)
Evaluate an expression as a String. |
Item |
evaluateItem(XPathContext context)
Evaluate as an item |
int |
getCardinality()
Determine the static cardinality |
int |
getImplementationMethod()
An implementation of Expression must provide at least one of the methods evaluateItem(), iterate(), or process(). |
ItemType |
getItemType(TypeHierarchy th)
Determine the data type of the items in the expression. |
int |
getLength()
Get the length of the sequence |
NodeInfo |
getNode()
Get the node that forms the node-set. |
int |
getSpecialProperties()
Get the static properties of this expression (other than its type). |
java.lang.String |
getStringValue()
Convert the value to a string, using the serialization rules. |
Item |
itemAt(int n)
Get the n'th item in the sequence (starting from 0). |
SequenceIterator |
iterate(XPathContext context)
Return an enumeration of this nodeset value. |
void |
process(XPathContext context)
Process the instruction, without returning any tail calls |
| Methods inherited from class net.sf.saxon.value.Value |
asItem, asIterator, asValue, checkPermittedContents, collapseWhitespace, convert, convertJavaObjectToXPath, equals, getDependencies, getIterator, getParentExpression, hashCode, iterateSubExpressions, makeQNameValue, normalizeWhitespace, optimize, promote, reduce, schemaEquals, simplify, stringToNumber, toString, trimWhitespace, typeCheck |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
protected NodeInfo node
| Constructor Detail |
public SingletonNode(NodeInfo node)
node - The node to be contained in the node-set, or null if the node-set
is to be empty| Method Detail |
public int getImplementationMethod()
public void process(XPathContext context)
throws XPathException
process in interface Expressionprocess in class Valuecontext - The dynamic context, giving access to the current node,
the current variables, etc.
XPathExceptionpublic ItemType getItemType(TypeHierarchy th)
getItemType in interface ExpressiongetItemType in class Valueth -
public int getCardinality()
getCardinality in interface ExpressiongetCardinality in class Value
public int getLength()
throws XPathException
getLength in class ValueXPathException
public Item itemAt(int n)
throws XPathException
itemAt in class ValueXPathExceptionpublic NodeInfo getNode()
public int getSpecialProperties()
getSpecialProperties in interface ExpressiongetSpecialProperties in class ValueStaticProperty.NON_CREATIVEpublic SequenceIterator iterate(XPathContext context)
context - supplies the context for evaluation
public Item evaluateItem(XPathContext context)
evaluateItem in interface ExpressionevaluateItem in class Valuepublic boolean effectiveBooleanValue(XPathContext context)
effectiveBooleanValue in interface ExpressioneffectiveBooleanValue in class Valuecontext - The context in which the expression is to be evaluated
public java.lang.String getStringValue()
getStringValue in interface ValueRepresentationgetStringValue in class Value
public java.lang.String evaluateAsString(XPathContext context)
throws XPathException
evaluateAsString in interface ExpressionevaluateAsString in class Valuecontext - The context in which the expression is to be evaluated
XPathException - if any dynamic error occurs evaluating the
expression
public void display(int depth,
NamePool pool,
java.io.PrintStream out)
display in interface Expressiondisplay in class Value
public java.lang.Object convertToJava(java.lang.Class target,
XPathContext context)
throws XPathException
convertToJava in class ValueXPathException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||