FileDocCategorySizeDatePackage
DTMAxisIterator.javaAPI DocJava SE 6 API2872Tue Jun 10 00:22:56 BST 2008com.sun.org.apache.xml.internal.dtm

DTMAxisIterator

public interface DTMAxisIterator implements Cloneable
This class iterates over a single XPath Axis, and returns node handles.

Fields Summary
public static final int
END
Specifies the end of the iteration, and is the same as DTM.NULL.
Constructors Summary
Methods Summary
public com.sun.org.apache.xml.internal.dtm.DTMAxisIteratorcloneIterator()

return
a deep copy of this iterator. The clone should not be reset from its current position.

public intgetLast()

return
the number of nodes in this iterator. This may be an expensive operation when called the first time.

public intgetNodeByPosition(int position)
Return the node at the given position.

param
position The position
return
The node at the given position.

public intgetPosition()

return
The position of the current node in the set, as defined by XPath.

public intgetStartNode()
Get start to END should 'close' the iterator, i.e. subsequent call to next() should return END.

return
The root node of the iteration.

public voidgotoMark()
Restores the current node remembered by setMark().

public booleanisReverse()

return
true if this iterator has a reversed axis, else false.

public intnext()
Get the next node in the iteration.

return
The next node handle in the iteration, or END.

public com.sun.org.apache.xml.internal.dtm.DTMAxisIteratorreset()
Resets the iterator to the last start node.

return
A DTMAxisIterator, which may or may not be the same as this iterator.

public voidsetMark()
Remembers the current node for the next call to gotoMark().

public voidsetRestartable(boolean isRestartable)
Set if restartable.

public com.sun.org.apache.xml.internal.dtm.DTMAxisIteratorsetStartNode(int node)
Set start to END should 'close' the iterator, i.e. subsequent call to next() should return END.

param
node Sets the root of the iteration.
return
A DTMAxisIterator set to the start of the iteration.