Class TreeFragmentResult
java.lang.Object
org.exolab.adaptx.xpath.XPathResult
org.exolab.adaptx.xslt.XSLTFunctionResult
org.exolab.adaptx.xslt.TreeFragmentResult
- All Implemented Interfaces:
Serializable
Represents a TreeFragment result
- Version:
- $Revision: 4092 $ $Date: 2004-01-27 00:43:54 +0100 (Tue, 27 Jan 2004) $
- Author:
- Keith Visco
- See Also:
-
Field Summary
Fields inherited from class XSLTFunctionResult
TREE_FRAGMENTFields inherited from class XPathResult
BOOLEAN, NODE_SET, NUMBER, STRING, USER_DEFINED -
Constructor Summary
ConstructorsConstructorDescriptionCreates a new TreeFragmentResult that represents a "empty" fragment.TreeFragmentResult(NodeSet nodes) Creates a new TreeFragmentResult with the given NodeSet.TreeFragmentResult(XPathNode node) Creates a new TreeFragmentResult with the given XPathNode. -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns the value of this ExprResult as a booleanbooleanequals(XPathResult result) Returns true if the given expression is the same tyoe as this result and has the same value as this result.getValue()Returns the value of this TreeFragmentResultshortReturns the type of this result.Returns the Result as a Java Object.doubleReturns the value of this XPathResult as a doublevoidSets the value of this TreeFragmentResultvoidSets the value of this TreeFragmentResultReturns the result as a string value.toString()Methods inherited from class XSLTFunctionResult
getResultType
-
Constructor Details
-
TreeFragmentResult
public TreeFragmentResult()Creates a new TreeFragmentResult that represents a "empty" fragment. -
TreeFragmentResult
Creates a new TreeFragmentResult with the given XPathNode.- Parameters:
node- the XPathNode which is the "tree fragment".
-
TreeFragmentResult
Creates a new TreeFragmentResult with the given NodeSet.- Parameters:
nodes- the NodeSet which is the "tree fragment".
-
-
Method Details
-
getValue
Returns the value of this TreeFragmentResult- Returns:
- the value of this TreeFragmentResult
-
setValue
Sets the value of this TreeFragmentResult- Parameters:
node- the XPathNode to use as the result fragment
-
setValue
Sets the value of this TreeFragmentResult- Parameters:
nodes- the NodeSet to use as the result fragment
-
getXSLTResultType
public short getXSLTResultType()Returns the type of this result.- Specified by:
getXSLTResultTypein classXSLTFunctionResult- Returns:
- The type of this result
-
booleanValue
public boolean booleanValue()Returns the value of this ExprResult as a boolean- Specified by:
booleanValuein classXSLTFunctionResult- Returns:
- the value of this ExprResult as a boolean
-
equals
Returns true if the given expression is the same tyoe as this result and has the same value as this result.- Specified by:
equalsin classXSLTFunctionResult- Parameters:
result- An XPath result- Returns:
- True if same type and same value as this result
-
numberValue
public double numberValue()Returns the value of this XPathResult as a double- Specified by:
numberValuein classXSLTFunctionResult- Returns:
- the value of this XPathResult as a double
-
javaObject
Returns the Result as a Java Object. For tree-fragment this is simply an XPathNode.- Specified by:
javaObjectin classXSLTFunctionResult- Returns:
- the Result as a Java Object
-
stringValue
Returns the result as a string value. Returns "false" or "true" for a boolean result, the value of a string result, the string value of a number result, or the string value of a node-set.- Specified by:
stringValuein classXSLTFunctionResult- Returns:
- The result as a string value
-
toString
-