E - the elementpublic class FastListIterator<E> extends Object implements Iterator<E>
Iterator.remove() is not supported.
The iterator in Java, at least in older Java versions, is very slow,
causing a significant amount of time in operations in WorldEdit
being spent on Iterator.hasNext(). In contrast, the iterator
implemented by this class is very quick, as long as
List.get(int) is fast.
| Modifier and Type | Method and Description |
|---|---|
static <E> Iterator<E> |
forwardIterator(List<E> list)
Create a new forward iterator for the given list.
|
boolean |
hasNext() |
E |
next() |
void |
remove() |
static <E> Iterator<E> |
reverseIterator(List<E> list)
Create a new reverse iterator for the given list.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEachRemainingCopyright © 2010-2014. All Rights Reserved.