org.apache.xpath.axes

Class ReverseAxesWalker

Implemented Interfaces:
Cloneable, ExpressionNode, ExpressionOwner, PathComponent, Serializable, SourceLocator, SubContextList, XPathVisitable

public class ReverseAxesWalker
extends AxesWalker

Walker for a reverse axes.
See Also:
XPath 2.4 Predicates, Serialized Form

Field Summary

Fields inherited from class org.apache.xpath.patterns.NodeTest

SCORE_NODETEST, SCORE_NONE, SCORE_NSWILD, SCORE_OTHER, SCORE_QNAME, SHOW_BYFUNCTION, SUPPORTS_PRE_STRIPPING, WILD

Method Summary

void
detach()
Detaches the walker from the set which it iterated over, releasing any computational resources and placing the iterator in the INVALID state.
int
getLastPos(XPathContext xctxt)
Get the number of nodes in this node list.
boolean
isDocOrdered()
Returns true if all the nodes in the iteration well be returned in document order.
boolean
isReverseAxes()
Tells if this is a reverse axes.
void
setRoot(int root)
Set the root node of the TreeWalker.

Methods inherited from class org.apache.xpath.axes.AxesWalker

callVisitors, clone, deepEquals, detach, getAnalysisBits, getAxis, getCurrentNode, getDTM, getExpression, getLastPos, getNextWalker, getPrevWalker, getRoot, init, isDocOrdered, nextNode, setDefaultDTM, setExpression, setNextWalker, setPrevWalker, setRoot, wi

Methods inherited from class org.apache.xpath.axes.PredicatedNodeTest

acceptNode, callPredicateVisitors, canTraverseOutsideSubtree, clone, deepEquals, fixupVariables, getLastPos, getLocPathIterator, getPredicate, getPredicateCount, getPredicateIndex, getProximityPosition, getProximityPosition, initProximityPosition, isReverseAxes, resetProximityPositions, setLocPathIterator, setPredicateCount

Methods inherited from class org.apache.xpath.patterns.NodeTest

callVisitors, debugWhatToShow, deepEquals, execute, execute, execute, fixupVariables, getDefaultScore, getLocalName, getNamespace, getNodeTypeTest, getStaticScore, getWhatToShow, initNodeTest, initNodeTest, setLocalName, setNamespace, setStaticScore, setWhatToShow

Methods inherited from class org.apache.xpath.Expression

asIterator, asIteratorRaw, asNode, assertion, bool, canTraverseOutsideSubtree, deepEquals, error, execute, execute, execute, execute, executeCharsToContentHandler, exprAddChild, exprGetChild, exprGetNumChildren, exprGetParent, exprSetParent, fixupVariables, getColumnNumber, getExpressionOwner, getLineNumber, getPublicId, getSystemId, isNodesetExpr, isStableNumber, num, warn, xstr

Method Details

detach

public void detach()
Detaches the walker from the set which it iterated over, releasing any computational resources and placing the iterator in the INVALID state.
Overrides:
detach in interface AxesWalker

getLastPos

public int getLastPos(XPathContext xctxt)
Get the number of nodes in this node list. The function is probably ill named?
Specified by:
getLastPos in interface SubContextList
Overrides:
getLastPos in interface AxesWalker
Parameters:
xctxt - The XPath runtime context.
Returns:
the number of nodes in this node list.

isDocOrdered

public boolean isDocOrdered()
Returns true if all the nodes in the iteration well be returned in document order. Warning: This can only be called after setRoot has been called!
Overrides:
isDocOrdered in interface AxesWalker
Returns:
false.

isReverseAxes

public boolean isReverseAxes()
Tells if this is a reverse axes. Overrides AxesWalker#isReverseAxes.
Overrides:
isReverseAxes in interface PredicatedNodeTest
Returns:
true for this class.

setRoot

public void setRoot(int root)
Set the root node of the TreeWalker. (Not part of the DOM2 TreeWalker interface).
Overrides:
setRoot in interface AxesWalker
Parameters:
root - The context node of this step.

Copyright B) 2004 Apache XML Project. All Rights Reserved.