public final class ArrayIterator<E> extends DisposableIterator<E>
Modifier and Type | Method and Description |
---|---|
void |
dispose()
This method allows to declare that the iterator is not used anymoure.
|
static <E> ArrayIterator<E> |
getIterator(E[] elements) |
static <E> ArrayIterator<E> |
getIterator(E[] elements,
int size) |
boolean |
hasNext()
Returns true if the iteration has more elements.
|
E |
next()
Returns the next element in the iteration.
|
init, isReusable, remove
public static <E> ArrayIterator<E> getIterator(E[] elements, int size)
public static <E> ArrayIterator<E> getIterator(E[] elements)
public boolean hasNext()
public E next()
NoSuchElementException
- iteration has no more elements.public void dispose()
dispose
in class Disposable
Copyright © 2015. All rights reserved.