org.inria.ns.reflex.util
Class CollectionsHelper.IteratorCumulator

java.lang.Object
  extended by org.inria.ns.reflex.util.CollectionsHelper.IteratorCumulator
All Implemented Interfaces:
Iterator
Enclosing class:
CollectionsHelper

public static class CollectionsHelper.IteratorCumulator
extends Object
implements Iterator

An Iterator that browse 2 or 3 Iterators.


Constructor Summary
CollectionsHelper.IteratorCumulator(Iterator it1, Iterator it2)
          Create an iterator over 2 other iterators.
CollectionsHelper.IteratorCumulator(Iterator it1, Iterator it2, Iterator it3)
          Create an iterator over 3 other iterators.
 
Method Summary
 boolean hasNext()
           
 Object next()
           
 void remove()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CollectionsHelper.IteratorCumulator

public CollectionsHelper.IteratorCumulator(Iterator it1,
                                           Iterator it2,
                                           Iterator it3)
Create an iterator over 3 other iterators.

Parameters:
it1 - The first iterator to browse, that can be null.
it2 - The second iterator to browse, that can be null.
it3 - The third iterator to browse, that can be null.

CollectionsHelper.IteratorCumulator

public CollectionsHelper.IteratorCumulator(Iterator it1,
                                           Iterator it2)
Create an iterator over 2 other iterators.

Parameters:
it1 - The first iterator to browse, that can be null.
it2 - The second iterator to browse, that can be null.
Method Detail

hasNext

public boolean hasNext()
Specified by:
hasNext in interface Iterator
See Also:
Iterator.hasNext()

next

public Object next()
Specified by:
next in interface Iterator
See Also:
Iterator.next()

remove

public void remove()
Specified by:
remove in interface Iterator
See Also:
Iterator.remove()