public class ReverseIterator<E> extends SnapshotIterator<E>
ReverseIterator iterates through an Iterator
in reverse order. It extends SnapshotIterator, so is
insensitive to changes in the underlying collection once construction
is complete.| Constructor and Description |
|---|
ReverseIterator(Iterator<E> it)
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
hasNext()
Returns
true if the iteration has more elements. |
E |
next()
Returns the next element in the iteration.
|
proxy, removeclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEachRemainingpublic boolean hasNext()
UnmodifiableIteratortrue if the iteration has more elements.public E next()
UnmodifiableIteratorCopyright (c) 2006 C. Scott Ananian