DeferredGenerator<T> class final

The generator deferred returns, before and after it is defined.

Defined exactly once, and drawn from only after that. Both mistakes throw where they are made rather than producing a strange run: a generator with no definition has nothing to draw, and one defined twice means two recipes are in play and no reader can tell which the failure came from.

Inheritance

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

define(Generator<T> generator) → void
Says that this generator is generator.
flatMap<R>(Generator<R> choose(T value)) Generator<R>
The values of whichever generator choose picks for each of this one's.
inherited
generate(TestCase testCase) → T
Produces one value, drawing whatever it needs from testCase.
map<R>(R transform(T value)) Generator<R>
This generator's values, each put through transform.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited
where(bool predicate(T value)) Generator<T>
This generator's values that satisfy predicate, and no others.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited