cycle Iterator
Returns an iterator that cycles indefinitely over the elements of this.
The iterator's hasNext method returns true until this is empty.
Warning: Typical uses of the resulting iterator may produce an infinite loop. You should use an explicit break or be certain that you will eventually remove all the elements.
See also
Returns an iterator that cycles indefinitely over the elements of this.
The returned iterator supports remove if the provided iterator does. After remove is called, subsequent cycles omit the removed element, which is no longer in this. The iterator's hasNext method returns true until this is empty.
Warning: Typical uses of the resulting iterator may produce an infinite loop. You should use an explicit break or be certain that you will eventually remove all the elements.
See also
Returns an iterator that cycles indefinitely over the provided elements.
The returned iterator supports remove. After remove is called, subsequent cycles omit the removed element, but elements does not change. The iterator's hasNext method returns true until all of the original elements have been removed.
Warning: Typical uses of the resulting iterator may produce an infinite loop. You should use an explicit break or be certain that you will eventually remove all the elements.