|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.hpi.fgis.dude.util.AbstractIterator<T> de.hpi.fgis.dude.util.ChainedIterator<T>
T
- the type of the Iterator
public class ChainedIterator<T>
Logically concatenates several Iterator
s to one big iterator.
Constructor Summary | |
---|---|
ChainedIterator(Iterable<Iterator<T>> iterators)
Initializes the chained iterator from multiple single iterators. |
|
ChainedIterator(Iterator<Iterator<T>> iterators)
Initializes the chained iterator from multiple single iterators. |
|
ChainedIterator(Iterator<T>... iterators)
Initializes the chained iterator from multiple single iterators. |
Method Summary | ||
---|---|---|
static
|
fromIterables(Iterable<Iterable<T>> iterables)
Creates a chained iterator from Iterable s. |
|
protected T |
loadNextElement()
Returns the element of the next iteration step. |
Methods inherited from class de.hpi.fgis.dude.util.AbstractIterator |
---|
hasNext, next, remove |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ChainedIterator(Iterable<Iterator<T>> iterators)
iterators
- the iterators to chainpublic ChainedIterator(Iterator<Iterator<T>> iterators)
iterators
- the iterators to chainpublic ChainedIterator(Iterator<T>... iterators)
iterators
- the iterators to chainMethod Detail |
---|
public static <T> ChainedIterator<T> fromIterables(Iterable<Iterable<T>> iterables)
Iterable
s.
T
- the type of the Iterable
siterables
- the iterables from which to create a ChainedIterator
.
ChainedIterator
iterating over all iterablesprotected T loadNextElement()
AbstractIterator
loadNextElement
in class AbstractIterator<T>
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |