public static class Reverse.ReverseListIterator extends java.lang.Object implements SequenceIterator, LastPositionFinder, ReversibleIterator
| Constructor and Description |
|---|
ReverseListIterator(java.util.List<T> list) |
| Modifier and Type | Method and Description |
|---|---|
int |
getLength()
Get the last position (that is, the number of items in the sequence).
|
SequenceIterator |
getReverseIterator()
Get a new SequenceIterator that returns the same items in reverse order.
|
Item |
next()
Get the next item in the sequence.
|
boolean |
supportsGetLength()
Ask whether this iterator supports use of the
LastPositionFinder.getLength() method. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitclose, dischargepublic boolean supportsGetLength()
LastPositionFinderLastPositionFinder.getLength() method. This
method should always be called before calling LastPositionFinder.getLength(), because an iterator
that implements this interface may support use of LastPositionFinder.getLength() in some situations
and not in otherssupportsGetLength in interface LastPositionFinderLastPositionFinder.getLength() method can be called to determine the length
of the underlying sequence.public int getLength()
getLength in interface LastPositionFinderpublic Item next()
next in interface SequenceIteratorpublic SequenceIterator getReverseIterator()
getReverseIterator in interface ReversibleIteratorCopyright (c) 2004-2022 Saxonica Limited. All rights reserved.