org.sixdml.xindice
Class xiSixdmlXpathObject
java.lang.Object
|
+--org.sixdml.xindice.xiSixdmlXpathObject
- All Implemented Interfaces:
- SixdmlXpathObject
- public class xiSixdmlXpathObject
- extends Object
- implements SixdmlXpathObject
xiSixdmlXpathObject.java
Represents an object returned from an XPath query.
- Version:
- 1.0
|
Field Summary |
private org.apache.xpath.objects.XObject |
xpathObj
The Xalan XObject instance that this object acts as a wrapper for. |
|
Constructor Summary |
private |
xiSixdmlXpathObject()
Default constructor private because an instance of this class must always
be instantiated with an underlying eXcelon DXE XPathValue object. |
(package private) |
xiSixdmlXpathObject(org.apache.xpath.objects.XObject xpathVal)
Initializes this class with an XObject instance. |
| Methods inherited from class java.lang.Object |
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait |
xpathObj
private org.apache.xpath.objects.XObject xpathObj
- The Xalan XObject instance that this object acts as a wrapper for.
xiSixdmlXpathObject
private xiSixdmlXpathObject()
- Default constructor private because an instance of this class must always
be instantiated with an underlying eXcelon DXE XPathValue object.
xiSixdmlXpathObject
xiSixdmlXpathObject(org.apache.xpath.objects.XObject xpathVal)
- Initializes this class with an XObject instance.
- Parameters:
xpathVal - the XObject instance.
getType
public SixdmlXpathObjectType getType()
- Get the type of this object as a SixdmlXpathObjectType.
- Specified by:
getType in interface SixdmlXpathObject
- Returns:
- the type of this object.
getObjectAsBoolean
public boolean getObjectAsBoolean()
- Returns the object as a boolean.
- Specified by:
getObjectAsBoolean in interface SixdmlXpathObject
- Returns:
- the object as a boolean.
getObjectAsString
public String getObjectAsString()
- Returns the object as a string. For a nodeset the text form of the first element in the set
is returned to be compatible with the XPath spec. For retrieval of the entire XML from
a nodeset the
getNodeSetAsXML() method should be used.
- Specified by:
getObjectAsString in interface SixdmlXpathObject
- Returns:
- the object as a string.
- See Also:
getNodeSetAsXML()
getObjectAsNumber
public double getObjectAsNumber()
- Returns the object as a double.
- Specified by:
getObjectAsNumber in interface SixdmlXpathObject
- Returns:
- the object as a double.
getObjectAsNodeSet
public NodeList getObjectAsNodeSet()
- Returns the object as a DOM node list.
- Specified by:
getObjectAsNodeSet in interface SixdmlXpathObject
- Returns:
- the object as a DOM node list.
getNodeSetAsXML
public String getNodeSetAsXML()
- Returns the contents of the object as an XML string if it is a nodeset or
null otherwise.
- Specified by:
getNodeSetAsXML in interface SixdmlXpathObject
- Returns:
- the entire contents of the object as a string if it is a nodeset or null otherwise.