Class MemorisingIterable.MemorisingIterator<T>

java.lang.Object
com.atlassian.bamboo.utils.MemorisingIterable.MemorisingIterator<T>
Type Parameters:
T - type of elements returned by this iterator
All Implemented Interfaces:
Iterator<T>
Enclosing class:
MemorisingIterable<T>

public static class MemorisingIterable.MemorisingIterator<T> extends Object implements Iterator<T>
Iterator which memorises all traversed elements.
  • Constructor Details

  • Method Details

    • hasNext

      public boolean hasNext()
      Specified by:
      hasNext in interface Iterator<T>
    • next

      public T next()
      Specified by:
      next in interface Iterator<T>
    • getTraversedElements

      @NotNull public @NotNull List<T> getTraversedElements()
      Returns a list of all elements already traversed by calling Iterator.next() on this object.