public class IteratorCons<T> extends Object implements Iterator<T>, Iterable<T>
IteratorConcat.
If there potentially many iterators to be joined, it is better to
create an IteratorConcat explicitly and add each iterator.
IteratorCons is slightly better in the two iterator case.| Modifier and Type | Method and Description |
|---|---|
static <X> Iterator<X> |
create(Iterator<? extends X> iter1,
Iterator<? extends X> iter2) |
boolean |
hasNext() |
Iterator<T> |
iterator() |
T |
next() |
void |
remove() |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEachRemainingforEach, spliteratorLicenced under the Apache License, Version 2.0