Modifier and Type | Field and Description |
---|---|
protected int | m_axis
The traversal axis from where the nodes will be filtered. |
private transient int | m_currentNode
The node at which the TreeWalker is currently positioned. |
private DTM | m_dtm
The DTM for the root. |
pack-priv transient boolean | m_isFresh
True if an itteration has not begun. |
protected AxesWalker | m_nextWalker
The next walker in the location step chain. |
pack-priv AxesWalker | m_prevWalker
The previous walker in the location step chain, or null. |
pack-priv transient int | m_root
The root node of the TreeWalker, as specified when it was created. |
protected DTMAxisTraverser | m_traverser
The DTM inner traversal class, that corresponds to the super axis. |
pack-priv static final long |
Access | Constructor and Description |
---|---|
public | AxesWalker(LocPathIterator
non-null reference to the parent iterator. locPathIterator, int axis)Construct an AxesWalker using a LocPathIterator. |
Modifier and Type | Method and Description |
---|---|
public void | callVisitors(ExpressionOwner
The owner of the visitor, where that path may be
rewritten if needed. owner, XPathVisitor The visitor whose appropriate method will be called. visitor)Overrides com. Implements com. This will traverse the heararchy, calling the visitor for each member. |
public Object | Returns: A new AxesWalker that can be used without mutating this one.Overrides com. Get a cloned AxesWalker. |
pack-priv AxesWalker | Returns: non-null clone, which may be a new clone, or may be a clone contained on the cloneList.non-null reference to the cloned location path
iterator to which this clone will be added. cloneOwner, List<AxesWalker> non-null vector of sources in odd elements, and the
corresponding clones in even vectors. cloneList)Do a deep clone of this walker, including next and previous walkers. |
public boolean | deepEquals(Expression
Another expression object. expr)Overrides com. Compare this object with another object and see if they are equal, include the sub heararchy. |
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. |
pack-priv static AxesWalker | Returns: A clone that corresponds to the key, or null if key not found.The original AxesWalker for which there may be a clone. key, List<AxesWalker> vector of sources in odd elements, and the
corresponding clones in even vectors, may be null. cloneList)Find a clone that corresponds to the key argument. |
public int | Returns: One of WalkerFactory#BIT_DESCENDANT, etc.Implements com. Get the analysis bits for this walker, as defined in the WalkerFactory. |
public int | Returns: Axis.CHILD, etc., or -1 if the axis is not known or is of multiple types.Returns the axis being iterated, if it is known. |
public final int | Returns: The node at which the TreeWalker is currently positioned, only null if setRoot has not yet been called.The node at which the TreeWalker is currently positioned. |
public DTM | |
public Expression | getExpression()
Implements com. Get the raw Expression object that this class wraps. |
public int | Returns: the index of the last node that can be itterated to.XPath runtime context. xctxt)Implements abstract com. Implements com. Get the index of the last node that can be itterated to. |
protected int | Returns: the next node in document order on the axes, or null.Get the next node in document order on the axes. |
public AxesWalker | Returns: Reference to AxesWalker derivative, or null.Get the next walker in the location step chain. |
public AxesWalker | Returns: Reference to previous walker reference in the location step chain, or null.Get the previous walker reference in the location step chain. |
public int | Returns: The context node of the step.The root node of the TreeWalker, as specified in setRoot(int root). |
public void | |
public boolean | Returns: true as a default.Returns true if all the nodes in the iteration well be returned in document order. |
public int | Returns: The new node, ornull if the current node has no
next node in the TreeWalker's logical view.Moves the |
private int | Returns: The argument.Node to return, or null. n)This is simply a way to bottle-neck the return of the next node, for diagnostic purposes. |
public void | |
public void | setExpression(Expression
the raw Expression object, which should not normally be null. exp)Implements com. Set the raw expression object for this object. |
public void | setNextWalker(AxesWalker
Reference to AxesWalker derivative, or may be null. walker)Set the next walker in the location step chain. |
public void | setPrevWalker(AxesWalker
Reference to previous walker reference in the location
step chain, or null. walker)Set or clear the previous walker reference in the location step chain. |
public void | |
public final WalkingIterator |
m_axis | back to summary |
---|---|
protected int m_axis The traversal axis from where the nodes will be filtered. |
m_currentNode | back to summary |
---|---|
private transient int m_currentNode The node at which the TreeWalker is currently positioned. |
m_dtm | back to summary |
---|---|
private DTM m_dtm The DTM for the root. This can not be used, or must be changed, for the filter walker, or any walker that can have nodes from multiple documents. Never, ever, access this value without going through getDTM(int node).
|
m_isFresh | back to summary |
---|---|
pack-priv transient boolean m_isFresh True if an itteration has not begun. |
m_nextWalker | back to summary |
---|---|
protected AxesWalker m_nextWalker The next walker in the location step chain. |
m_prevWalker | back to summary |
---|---|
pack-priv AxesWalker m_prevWalker The previous walker in the location step chain, or null. |
m_root | back to summary |
---|---|
pack-priv transient int m_root The root node of the TreeWalker, as specified when it was created. |
m_traverser | back to summary |
---|---|
protected DTMAxisTraverser m_traverser The DTM inner traversal class, that corresponds to the super axis.
|
serialVersionUID | back to summary |
---|---|
pack-priv static final long serialVersionUID Hides com. |
AxesWalker | back to summary |
---|---|
public AxesWalker(LocPathIterator locPathIterator, int axis) Construct an AxesWalker using a LocPathIterator.
|
callVisitors | back to summary |
---|---|
public void callVisitors(ExpressionOwner owner, XPathVisitor visitor) Overrides com. Implements com. This will traverse the heararchy, calling the visitor for each member. If the called visitor method returns false, the subtree should not be called.
|
clone | back to summary |
---|---|
public Object clone() throws CloneNotSupportedException Overrides com. Get a cloned AxesWalker.
|
cloneDeep | back to summary |
---|---|
pack-priv AxesWalker cloneDeep(WalkingIterator cloneOwner, List<AxesWalker> cloneList) throws CloneNotSupportedException Do a deep clone of this walker, including next and previous walkers. If the this AxesWalker is on the clone list, don't clone but return the already cloned version.
|
deepEquals | back to summary |
---|---|
public boolean deepEquals(Expression expr) Overrides com. Doc from com. Compare this object with another object and see if they are equal, include the sub heararchy.
|
detach | back to summary |
---|---|
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. |
findClone | back to summary |
---|---|
pack-priv static AxesWalker findClone(AxesWalker key, List<AxesWalker> cloneList) Find a clone that corresponds to the key argument.
|
getAnalysisBits | back to summary |
---|---|
public int getAnalysisBits() Implements com. Get the analysis bits for this walker, as defined in the WalkerFactory.
|
getAxis | back to summary |
---|---|
public int getAxis() Returns the axis being iterated, if it is known.
|
getCurrentNode | back to summary |
---|---|
public final int getCurrentNode() The node at which the TreeWalker is currently positioned.
|
getDTM | back to summary |
---|---|
public DTM getDTM(int node) Get the DTM for this walker.
|
getExpression | back to summary |
---|---|
public Expression getExpression() Implements com. Doc from com. Get the raw Expression object that this class wraps.
|
getLastPos | back to summary |
---|---|
public int getLastPos(XPathContext xctxt) Implements abstract com. Implements com. Get the index of the last node that can be itterated to.
|
getNextNode | back to summary |
---|---|
protected int getNextNode() Get the next node in document order on the axes.
|
getNextWalker | back to summary |
---|---|
public AxesWalker getNextWalker() Get the next walker in the location step chain.
|
getPrevWalker | back to summary |
---|---|
public AxesWalker getPrevWalker() Get the previous walker reference in the location step chain.
|
getRoot | back to summary |
---|---|
public int getRoot() The root node of the TreeWalker, as specified in setRoot(int root). Note that this may actually be below the current node.
|
init | back to summary |
---|---|
public void init(Compiler compiler, int opPos, int stepType) throws TransformerException Initialize an AxesWalker during the parse of the XPath expression.
|
isDocOrdered | back to summary |
---|---|
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!
|
nextNode | back to summary |
---|---|
public int nextNode() Moves the
|
returnNextNode | back to summary |
---|---|
private int returnNextNode(int n) This is simply a way to bottle-neck the return of the next node, for diagnostic purposes.
|
setDefaultDTM | back to summary |
---|---|
public void setDefaultDTM(DTM dtm) Set the DTM for this walker.
|
setExpression | back to summary |
---|---|
public void setExpression(Expression exp) Implements com. Doc from com. Set the raw expression object for this object.
|
setNextWalker | back to summary |
---|---|
public void setNextWalker(AxesWalker walker) Set the next walker in the location step chain.
|
setPrevWalker | back to summary |
---|---|
public void setPrevWalker(AxesWalker walker) Set or clear the previous walker reference in the location step chain.
|
setRoot | back to summary |
---|---|
public void setRoot(int root) Set the root node of the TreeWalker. (Not part of the DOM2 TreeWalker interface).
|
wi | back to summary |
---|---|
public final WalkingIterator wi() |