Class IteratorUtil.AbstractIterator<T>

    • Constructor Detail

      • AbstractIterator

        public AbstractIterator()
    • Method Detail

      • hasNext

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

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

        protected final void setNext​(T t)
      • done

        protected final void done()
      • computeNext

        protected abstract void computeNext()
        Compute the next element. Implementations must call either done() or setNext(Object) exactly once.