|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.saxon.sxpath.XPathExpression
This class is a representation of an XPath Expression for use with the XPathEvaluator class. It is modelled on the XPath API defined in JAXP 1.3, but is cut down to remove any dependencies on JAXP 1.3, making it suitable for use on vanilla JDK 1.4 installations.
Constructor Summary | |
protected |
XPathExpression(XPathEvaluator evaluator,
Expression exp)
The constructor is protected, to ensure that instances can only be created using the createExpression() method of XPathEvaluator |
Method Summary | |
java.util.List |
evaluate(javax.xml.transform.Source source)
Execute a prepared XPath expression, returning the results as a List. |
java.lang.Object |
evaluateSingle(javax.xml.transform.Source source)
Execute a prepared XPath expression, returning the first item in the result. |
Expression |
getInternalExpression()
Low-level method to get the internal Saxon expression object. |
SequenceIterator |
rawIterator(javax.xml.transform.Source source)
Get a raw iterator over the results of the expression. |
protected void |
setStackFrameMap(SlotManager map)
Define the number of slots needed for local variables within the expression |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
protected XPathExpression(XPathEvaluator evaluator, Expression exp)
Method Detail |
protected void setStackFrameMap(SlotManager map)
public java.util.List evaluate(javax.xml.transform.Source source) throws XPathException
source
- the document or other node against which the XPath expression
will be evaluated. This may be a Saxon NodeInfo object, representing a node in an
existing tree, or it may be any kind of JAXP Source object such as a StreamSource
SAXSource or DOMSource.
XPathException
public java.lang.Object evaluateSingle(javax.xml.transform.Source source) throws XPathException
source
- the document or other node against which the XPath expression
will be evaluated. This may be a Saxon NodeInfo object, representing a node in an
existing tree, or it may be any kind of JAXP Source object such as a StreamSource
SAXSource or DOMSource.
XPathException
public SequenceIterator rawIterator(javax.xml.transform.Source source) throws XPathException
source
- the document or other node against which the XPath expression
will be evaluated. This may be a Saxon NodeInfo object, representing a node in an
existing tree, or it may be any kind of JAXP Source object such as a StreamSource
SAXSource or DOMSource.
XPathException
public Expression getInternalExpression()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |