org.apache.xalan.xsltc.dom

Class KeyIndex.KeyIndexIterator

public class KeyIndex.KeyIndexIterator extends MultiValuedNodeHeapIterator

An iterator representing the result of a reference to either the XSLT key function or the XPath id function.
Method Summary
intgetLast()
Returns the number of nodes in this iterator.
intgetNodeByPosition(int position)
Return the node at the given position.
intnext()
Get the next node in the iteration.
DTMAxisIteratorreset()
Resets the iterator to the last start node.
DTMAxisIteratorsetStartNode(int node)
Set context node for the iterator.

Method Detail

getLast

public int getLast()
Returns the number of nodes in this iterator.

Returns: the number of nodes

getNodeByPosition

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

Parameters: position The position

Returns: The node at the given position.

next

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

Returns: The next node handle in the iteration, or END.

reset

public DTMAxisIterator reset()
Resets the iterator to the last start node.

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

setStartNode

public DTMAxisIterator setStartNode(int node)
Set context node for the iterator. This will cause the iterator to reset itself, reevaluate arguments to the function, look up nodes in the input and reinitialize its internal heap.

Parameters: node the context node

Returns: A DTMAxisIterator set to the start of the iteration.

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