@Mutable public class GeneratingIterator<ELEMENT> extends InfiniteIterator<ELEMENT>
| Modifier and Type | Field and Description |
|---|---|
protected @Nonnull FailableProducer<? extends ELEMENT,?> |
producer |
| Modifier | Constructor and Description |
|---|---|
protected |
GeneratingIterator(@Nonnull FailableProducer<? extends ELEMENT,?> producer) |
| Modifier and Type | Method and Description |
|---|---|
ELEMENT |
next() |
static <ELEMENT> @Nonnull GeneratingIterator<ELEMENT> |
with(@Nonnull FailableProducer<? extends ELEMENT,?> producer)
Returns a new generating iterator that generates an infinite number of elements with the given producer.
|
hasNextremoveclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEachRemaining@Nonnull protected final @Nonnull FailableProducer<? extends ELEMENT,?> producer
protected GeneratingIterator(@Captured @Nonnull @Nonnull FailableProducer<? extends ELEMENT,?> producer)
@Pure @Capturable @Nonnull public static <ELEMENT> @Nonnull GeneratingIterator<ELEMENT> with(@Captured @Nonnull @Nonnull FailableProducer<? extends ELEMENT,?> producer)
Copyright © 2017. All rights reserved.