Interface Counter<T>

Type Parameters:
T - the generic type of the elements being generated.
All Superinterfaces:
Generator<T>, Iterator<T>, org.refcodes.mixin.Resetable
All Known Subinterfaces:
IdCounter
All Known Implementing Classes:
AbstractCounterComposite, AlphabetCounter, AlphabetCounterComposite, IdCounterComposite

public interface Counter<T> extends Generator<T>, org.refcodes.mixin.Resetable
A Counter is a Generator with means to reset the Counter state to its initial position (value) from which to begin counting again, e.g. when Generator.hasNext() returns false, then calling Resetable.reset() will make the Counter instance to start again from the very first beginning and Generator.hasNext() will return true until the "end" of the countable elements has been reached (by consuming them with Generator.next()).