|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.util.CompositeIterator<E>
public class CompositeIterator<E>
Iterator that combines multiple other iterators. This implementation maintains a list of iterators which are invoked in sequence until all iterators are exhausted.
Field Summary | |
---|---|
private boolean |
inUse
|
private java.util.List<java.util.Iterator<E>> |
iterators
|
Constructor Summary | |
---|---|
CompositeIterator()
Create a new composite iterator. |
Method Summary | |
---|---|
void |
add(java.util.Iterator<E> iterator)
Add given iterator to this composite. |
boolean |
hasNext()
|
E |
next()
|
void |
remove()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private java.util.List<java.util.Iterator<E>> iterators
private boolean inUse
Constructor Detail |
---|
public CompositeIterator()
add(Iterator)
method.
Method Detail |
---|
public void add(java.util.Iterator<E> iterator)
public boolean hasNext()
hasNext
in interface java.util.Iterator<E>
public E next()
next
in interface java.util.Iterator<E>
public void remove()
remove
in interface java.util.Iterator<E>
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |