public class AxesWalker extends PredicatedNodeTest implements Cloneable, PathComponent
| Modifier and Type | Field and Description |
|---|---|
protected int |
m_axis
The traversal axis from where the nodes will be filtered.
|
protected AxesWalker |
m_nextWalker
The next walker in the location step chain.
|
protected DTMAxisTraverser |
m_traverser
The DTM inner traversal class, that corresponds to the super axis.
|
m_foundLast, m_lpi, m_predCount, m_proximityPositionsm_name, m_whatToShow, SCORE_NODETEST, SCORE_NONE, SCORE_NSWILD, SCORE_OTHER, SCORE_QNAME, SHOW_BYFUNCTION, WILD| Constructor and Description |
|---|
AxesWalker(LocPathIterator locPathIterator,
int axis)
Construct an AxesWalker using a LocPathIterator.
|
| Modifier and Type | Method and Description |
|---|---|
void |
callVisitors(XPathVisitor visitor)
This will traverse the hierarchy, calling the visitor for each member.
|
Object |
clone() |
boolean |
deepEquals(Expression expr)
Compare this object with another object and see if they are equal, include the sub heararchy.
|
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 |
getAnalysisBits()
Get the analysis bits for this path component, as defined in the WalkerFactory.
|
int |
getAxis()
Returns the axis being iterated, if it is known.
|
DTM |
getDTM(int node)
Get the DTM for this walker.
|
int |
getLastPos(XPathContext xctxt)
Get the number of nodes in the node list, which, in the XSLT 1 based counting system, is the
last index position.
|
protected int |
getNextNode()
Get the next node in document order on the axes.
|
AxesWalker |
getNextWalker()
Get the next walker in the location step chain.
|
int |
getRoot()
The root node of the TreeWalker, as specified in setRoot(int root).
|
void |
init(Compiler compiler,
int opPos,
int stepType)
Initialize an AxesWalker during the parse of the XPath expression.
|
int |
nextNode()
Moves the
TreeWalker to the next visible node in document order relative to the
current node, and returns the new node. |
void |
setNextWalker(AxesWalker walker)
Set the next walker in the location step chain.
|
void |
setPrevWalker(AxesWalker walker)
Set or clear the previous walker reference in the location step chain.
|
void |
setRoot(int root)
Set the root node of the TreeWalker.
|
WalkingIterator |
wi() |
acceptNode, callPredicateVisitors, canTraverseOutsideSubtree, countProximityPosition, getPredicate, getPredicateCount, getProximityPosition, getProximityPosition, getProximityPosition, initPredicateInfo, initProximityPosition, isReverseAxes, nodeToString, resetProximityPositions, setLocPathIterator, setPredicateCountcalcScore, execute, execute, execute, getLocalName, getNamespace, getNodeTypeTest, getStaticScore, getWhatToShow, initNodeTest, initNodeTest, setLocalName, setNamespace, setStaticScore, setWhatToShowasIterator, asNode, assertion, bool, error, execute, exprGetParent, exprSetParent, getColumnNumber, getExpressionOwner, getLineNumber, getPublicId, getSystemId, isSameClass, isStableNumber, numprotected AxesWalker m_nextWalker
protected final int m_axis
protected DTMAxisTraverser m_traverser
public AxesWalker(LocPathIterator locPathIterator, int axis)
locPathIterator - non-null reference to the parent iterator.public final WalkingIterator wi()
public void init(Compiler compiler, int opPos, int stepType) throws TransformerException
compiler - The Compiler object that has information about this walker in the op map.opPos - The op code position of this location step.stepType - The type of location step.TransformerException - if anypublic Object clone() throws CloneNotSupportedException
clone in class PredicatedNodeTestCloneNotSupportedExceptionpublic void detach()
public int getRoot()
public int getAnalysisBits()
getAnalysisBits in interface PathComponentpublic void setRoot(int root)
root - The context node of this step.public void setNextWalker(AxesWalker walker)
walker - Reference to AxesWalker derivative, or may be null.public AxesWalker getNextWalker()
public void setPrevWalker(AxesWalker walker)
walker - Reference to previous walker reference in the location step chain, or null.protected int getNextNode()
public int nextNode()
TreeWalker to the next visible node in document order relative to the
current node, and returns the new node. If the current node has no next node, or if the search
for nextNode attempts to step upward from the TreeWalker's root node, returns
null , and retains the current node.null if the current node has no next node in the
TreeWalker's logical view.public int getLastPos(XPathContext xctxt)
getLastPos in interface SubContextListgetLastPos in class PredicatedNodeTestxctxt - The XPath runtime context.public DTM getDTM(int node)
public int getAxis()
public void callVisitors(XPathVisitor visitor)
callVisitors in interface XPathVisitablecallVisitors in class NodeTestvisitor - The visitor whose appropriate method will be called.public boolean deepEquals(Expression expr)
deepEquals in class PredicatedNodeTestexpr - Another expression object.Copyright © 2022–2023. All rights reserved.