Class CompositeIterator<E>

  • All Implemented Interfaces:
    Iterator<E>

    public class CompositeIterator<E>
    extends Object
    implements Iterator<E>
    Composite iterator
    • Constructor Detail

      • CompositeIterator

        public CompositeIterator​(Iterator<E>... iterators)
        Create new instance of this class by specified iterators
        Parameters:
        iterators -
    • Method Detail

      • getDelegate

        protected Iterator<E> getDelegate()
        Get delegate iterator
        Returns:
        delegate iterator
      • hasNext

        public boolean hasNext()
        Implementation of the java.util.Iterator#hasNext(). Delegates this method to the current iterator.
        Specified by:
        hasNext in interface Iterator<E>
        See Also:
        Iterator.hasNext()
      • remove

        public void remove()
        Implementation of the java.util.Iterator#remove(). Delegates this method to the current iterator.
        Specified by:
        remove in interface Iterator<E>
        See Also:
        Iterator.remove()
      • next

        public E next()
        Implementation of the java.util.Iterator#next(). Delegates this method to the current iterator.
        Specified by:
        next in interface Iterator<E>
        See Also:
        Iterator.next()