| Modifier and Type | Interface and Description |
|---|---|
interface |
Cardinality
Describes how and how many values should be fetched from a
Generator. |
static interface |
Cardinality.Fetcher
Retrieves elements from a generator.
|
static interface |
Distribution.RandomNumbers
A random number generator based on a
Distribution. |
interface |
Generator<T>
Endlessly produces values.
|
interface |
Sequence<T>
A source of values supporting random access.
|
interface |
Template<T>
Creates generators that will always produce the same values.
|
interface |
Values<T>
A list of values that has been produced by a generator.
|
| Modifier and Type | Method and Description |
|---|---|
default DataSource<Double> |
Distribution.values(long seed)
Converts this distribution into a data source.
|
| Modifier and Type | Method and Description |
|---|---|
default <T> Values<T> |
Cardinality.Fetcher.of(DataSource<T> generator)
Fetches elements from
generator. |
default <T> Values<T> |
Cardinality.Fetcher.ofEach(DataSource<? extends T>... generators)
Fetches elements from each generator.
|
static FlTemplate<String> |
Fixsure.strings(DataSource<Character> characters)
Generates random strings.
|
static FlTemplate<String> |
Fixsure.strings(DataSource<Character> characters,
DataSource<Integer> length)
Generates random strings.
|
static FlTemplate<String> |
Fixsure.strings(DataSource<Character> characters,
DataSource<Integer> length)
Generates random strings.
|
static FlTemplate<String> |
Fixsure.strings(DataSource<Character> characters,
int length)
Generates random strings.
|
static <T> Generator<T>[] |
DataSource.toGenerators(DataSource<T>... sources)
Converts an array of data sources into generators by calling
toGenerator() on each. |
static <T> Generator<T>[] |
DataSource.toGenerators(DataSource<T> first,
DataSource<T>... more)
Converts data sources into generators by calling
toGenerator() on each. |
static <T> Generator<T>[] |
DataSource.toGenerators(DataSource<T> first,
DataSource<T>... more)
Converts data sources into generators by calling
toGenerator() on each. |
| Modifier and Type | Class and Description |
|---|---|
class |
AbstractDistributionRandom
Base class for
RandomNumberss. |
protected static class |
GaussianDistribution.GDRandom |
protected static class |
UniformDistribution.UDRandom |
| Modifier and Type | Interface and Description |
|---|---|
interface |
Factory<T> |
static interface |
Factory.FactoryGenerator<T> |
| Modifier and Type | Class and Description |
|---|---|
class |
DefaultFactory<V> |
static class |
ValueGenerator.VG2G<T> |
| Modifier and Type | Method and Description |
|---|---|
FactoriesSetup |
FactoriesSetup.add(String key,
DataSource<?> dataSource)
Adds a data source.
|
default FactoriesSetup |
FactoriesSetup.FactorySetup.add(String key,
DataSource<?> dataSource) |
FactoriesSetup |
DefaultFactories.Setup.add(String key,
DataSource<?> dataSource) |
default <T> FactoriesSetup |
FactoriesSetup.add(Typed<T> token,
DataSource<? extends T> dataSource)
Adds a data source.
|
static <T> ValueSource<T> |
ValueSource.fromDataSource(DataSource<? extends T> source) |
default BuilderSetup |
FactoriesSetup.ValueDeclaration.to(DataSource<? extends T> dataSource)
Use the data source to obtain values.
|
| Modifier and Type | Method and Description |
|---|---|
default FactoriesSetup |
FactoriesSetup.add(String key,
Supplier<? extends DataSource<?>> dataSupplier)
Adds a supplier as a data source.
|
default <T> FactoriesSetup |
FactoriesSetup.add(Typed<T> token,
Supplier<? extends DataSource<? extends T>> dataSupplier)
Adds a supplier as a data source.
|
static <T> ValueSource<T> |
ValueSource.fromDataSupply(Supplier<? extends DataSource<? extends T>> source) |
default BuilderSetup |
FactoriesSetup.ValueDeclaration.to(Supplier<? extends DataSource<? extends T>> dataSupplier)
Use a supplier as a data source to obtain values.
|
| Modifier and Type | Interface and Description |
|---|---|
static interface |
EagerFetcher.Template |
static interface |
LazyFetcher.Template |
| Modifier and Type | Class and Description |
|---|---|
class |
AbstractFetcher
Base class for
Fetchers. |
class |
EagerFetcher |
protected static class |
EagerFetcher.EagerCombinedValues<T> |
class |
FetcherWithScalar
A
Fetcher that requires a scalar value. |
class |
LazyFetcher |
protected static class |
LazyFetcher.LazyCombinedValues<T> |
| Modifier and Type | Method and Description |
|---|---|
void |
LazyFetcher.LazyCombinedValues.__addMore(int n,
DataSource<? extends T> g) |
void |
EagerFetcher.EagerCombinedValues.__addMore(int n,
DataSource<? extends T> g) |
void |
AbstractFetcher.CombinableValues.__addMore(int n,
DataSource<? extends T> g) |
static LazyFetcher |
Fetchers.any(DataSource<Integer> lengthGenerator) |
static Cardinality |
Fetchers.cardinality(DataSource<Integer> lengthGenerator) |
static Cardinality.Fetcher |
Fetchers.fetcher(DataSource<Integer> lengthGenerator) |
static EagerFetcher.Template |
Fetchers.first(DataSource<Integer> lengthGenerator) |
protected <T> AbstractFetcher.CombinableValues<T> |
LazyFetcher.newValues(int n,
DataSource<? extends T> g) |
protected <T> AbstractFetcher.CombinableValues<T> |
EagerFetcher.newValues(int n,
DataSource<? extends T> g) |
protected abstract <T> AbstractFetcher.CombinableValues<T> |
AbstractFetcher.newValues(int n,
DataSource<? extends T> g) |
static EagerFetcher.Template |
Fetchers.next(DataSource<Integer> lengthGenerator) |
<T> LazyValues<T> |
LazyFetcher.of(DataSource<T> generator) |
<T> EagerValues<T> |
EagerFetcher.of(DataSource<T> generator) |
<T> FlValues<T> |
AbstractFetcher.of(DataSource<T> generator) |
<T> LazyValues<T> |
LazyFetcher.ofEach(DataSource<? extends T>... generators) |
<T> EagerValues<T> |
EagerFetcher.ofEach(DataSource<? extends T>... generators) |
<T> FlValues<T> |
AbstractFetcher.ofEach(DataSource<? extends T>... generators) |
static <T> LazyValues<T> |
LazyFetcher.unbound(DataSource<T> generator) |
| Constructor and Description |
|---|
EagerCombinedValues(DataSource<? extends T> values,
int n) |
EagerFetcher(DataSource<Integer> lengthGenerator) |
FetcherWithScalar(DataSource<Integer> scalarGenerator) |
LazyCombinedValues(DataSource<? extends T> values,
int n) |
LazyFetcher(DataSource<Integer> lengthGenerator) |
| Modifier and Type | Interface and Description |
|---|---|
interface |
FlCardinality |
static interface |
FlCardinality.FlFetcher |
static interface |
FlCardinality.Template |
interface |
FlDataSource<T>
Extends the
DataSource interface with methods for data composition. |
static interface |
FlDistribution.FlRandom |
interface |
FlGenerator<T>
Extends the
Generator interface for fluent methods. |
interface |
FlSequence<T> |
interface |
FlTemplate<T> |
interface |
FlValues<T> |
| Modifier and Type | Method and Description |
|---|---|
default FlTemplate<Values<T>> |
FlTemplate.aggregate(DataSource<Integer> length) |
default FlGenerator<Values<T>> |
FlGenerator.aggregate(DataSource<Integer> length) |
FlDataSource<Values<T>> |
FlDataSource.aggregate(DataSource<Integer> length) |
default FlTemplate<T> |
FlTemplate.alternateWith(DataSource<? extends T>... more) |
default FlGenerator<T> |
FlGenerator.alternateWith(DataSource<? extends T>... more) |
FlDataSource<T> |
FlDataSource.alternateWith(DataSource<? extends T>... more) |
default <U,R> FlTemplate<R> |
FlTemplate.map(DataSource<U> other,
BiFunction<? super T,? super U,? extends R> function) |
default <U,R> FlGenerator<R> |
FlGenerator.map(DataSource<U> other,
BiFunction<? super T,? super U,? extends R> function) |
<U,R> FlDataSource<R> |
FlDataSource.map(DataSource<U> other,
BiFunction<? super T,? super U,? extends R> function) |
default FlTemplate<T> |
FlTemplate.mixWith(DataSource<? extends T>... more) |
default FlGenerator<T> |
FlGenerator.mixWith(DataSource<? extends T>... more) |
FlDataSource<T> |
FlDataSource.mixWith(DataSource<? extends T>... more) |
default EagerValues<T> |
FlGenerator.next(DataSource<Integer> length) |
default <T> FlValues<T> |
FlCardinality.FlFetcher.of(DataSource<T> generator) |
default <T> FlValues<T> |
FlCardinality.FlFetcher.ofEach(DataSource<? extends T>... generators) |
default FlTemplate<T> |
FlTemplate.then(DataSource<? extends T>... more) |
default FlGenerator<T> |
FlGenerator.then(DataSource<? extends T>... more) |
FlDataSource<T> |
FlDataSource.then(DataSource<? extends T>... more) |
FlValues<T> |
FlValues.then(DataSource<? extends T> moreValues) |
FlValues<T> |
FlValues.then(Generator<Integer> n,
DataSource<? extends T> moreValues) |
FlValues<T> |
FlValues.then(int n,
DataSource<? extends T> moreValues) |
FlValues<T> |
FlValues.thenAll(DataSource<? extends T>... moreValues) |
default <U> BiTemplate<T,U> |
FlTemplate.with(DataSource<U> source) |
default <U> BiGenerator<T,U> |
FlGenerator.with(DataSource<U> source) |
<U> BiDataSource<T,U> |
FlDataSource.with(DataSource<U> source) |
| Modifier and Type | Method and Description |
|---|---|
default <R> FlTemplate<R> |
FlTemplate.flatMap(Function<? super T,? extends DataSource<R>> function) |
default <R> FlGenerator<R> |
FlGenerator.flatMap(Function<? super T,? extends DataSource<R>> function) |
<R> FlDataSource<R> |
FlDataSource.flatMap(Function<? super T,? extends DataSource<R>> function) |
| Modifier and Type | Interface and Description |
|---|---|
interface |
CopyableGenerator<T> |
| Modifier and Type | Class and Description |
|---|---|
class |
AnonymousGenerator<T> |
class |
AnonymousSequence<T> |
class |
AnonymousTemplate<T> |
class |
BoundedSequence<T> |
class |
GeneratorWithDistribution<T>
Base class for
Generators that require an distribution. |
class |
GeneratorWithScalar<T>
A
Generator that requires a scalar value (e.g., to generate
strings with a certain length). |
| Constructor and Description |
|---|
GeneratorWithScalar(DataSource<Integer> scalarGenerator) |
| Modifier and Type | Class and Description |
|---|---|
class |
DistinctGenerator<T>
Uses a HashSet to ensure values are not returned twice.
|
class |
FilteringGenerator<T>
Uses a HashSet to ensure values are not returned twice.
|
class |
FlatMappingGenerator<T> |
class |
GeneratorQueue<T>
A queue of generators that fetches a certain number of elements from
each and then uses the next.
|
class |
MappingGenerator<T> |
class |
MergingGenerator<T>
Merges multiple generators that produce sorted values into one.
|
class |
MixingGenerator<T>
Produces values from randomly selected generators.
|
class |
RandomizedSequenceGenerator<T>
Randomly selects elements from a sequence.
|
class |
RepeatingGenerator<T>
Converts a list of finite generators into an inifinte generator.
|
class |
RoundRobinGenerator<T> |
class |
RoundRobinSequence<T> |
class |
ShuffledSequenceGenerator<T>
Returns the elements of a sequence in random order.
|
class |
ShufflingGenerator<T> |
| Modifier and Type | Method and Description |
|---|---|
protected void |
GeneratorQueue._add(DataSource<? extends T> value) |
static <T> RoundRobinGenerator<T> |
RoundRobinGenerator.alternate(DataSource<? extends T>... generators) |
static <T> GeneratorQueue<T> |
GeneratorQueue.beginWith(DataSource<T> values) |
static <T> GeneratorQueue<T> |
GeneratorQueue.beginWith(Generator<Integer> n,
DataSource<T> values) |
static <T> GeneratorQueue<T> |
GeneratorQueue.beginWith(int n,
DataSource<T> values) |
static <T> DistinctGenerator<T> |
DistinctGenerator.distinct(DataSource<T> source) |
static <T> DistinctGenerator<T> |
DistinctGenerator.distinct(DataSource<T> source,
int maxAttempts) |
static <T> FilteringGenerator<T> |
FilteringGenerator.filter(DataSource<T> source,
Predicate<? super T> predicate) |
static <In,Out> FlatMappingGenerator<Out> |
FlatMappingGenerator.map(DataSource<In> src,
Function<? super In,? extends DataSource<Out>> function) |
static <In,Out> MappingGenerator<Out> |
MappingGenerator.map(DataSource<In> src,
Function<? super In,? extends Out> function) |
static <T> MergingGenerator<T> |
MergingGenerator.merge(DataSource<? extends T>... generators) |
static <T> MixingGenerator<T> |
MixingGenerator.mix(DataSource<? extends T>... sources) |
static <T> GeneratorQueue<T> |
GeneratorQueue.queue(DataSource<T>... values) |
static <T> RepeatingGenerator<T> |
RepeatingGenerator.repeat(DataSource<? extends T>... sources) |
static <T> RoundRobinGenerator<T> |
RoundRobinGenerator.rotate(DataSource<? extends T>... generators) |
static <T> ShufflingGenerator<T> |
ShufflingGenerator.shuffle(DataSource<T> source) |
static <T> ShufflingGenerator<T> |
ShufflingGenerator.shuffle(DataSource<T> source,
long seed) |
GeneratorQueue<T> |
GeneratorQueue.then(DataSource<? extends T>... more) |
GeneratorQueue<T> |
GeneratorQueue.thenAll(DataSource<? extends T>... moreValues) |
| Modifier and Type | Method and Description |
|---|---|
static <In,Out> FlatMappingGenerator<Out> |
FlatMappingGenerator.map(DataSource<In> src,
Function<? super In,? extends DataSource<Out>> function) |
| Constructor and Description |
|---|
FlatMappingGenerator(DataSource<Src> src,
Function<? super Src,? extends DataSource<T>> function) |
| Modifier and Type | Class and Description |
|---|---|
class |
BooleansGenerator
Generates random booleans.
|
class |
CharactersGenerator
Generates random characters.
|
static class |
CharactersGenerator.FromString |
static class |
CharactersGenerator.InRange |
class |
ConsecutiveIntegersSequence
Generates consecutive integers.
|
class |
DoublesGenerator
Generates random doubles in a given range.
|
class |
RandomIntegersGenerator
Generates random integers in a given range.
|
static class |
RandomIntegersGenerator.Template |
class |
StringsGenerator
Generates random strings.
|
| Modifier and Type | Method and Description |
|---|---|
static FlTemplate<Character> |
CharactersGenerator.characters(DataSource<Integer> range)
Converts integers to characters
|
static FlTemplate<String> |
StringsGenerator.strings(DataSource<Character> characters)
Generates random strings.
|
static FlTemplate<String> |
StringsGenerator.strings(DataSource<Character> characters,
DataSource<Integer> length)
Generates random strings.
|
static FlTemplate<String> |
StringsGenerator.strings(DataSource<Character> characters,
DataSource<Integer> length)
Generates random strings.
|
static FlTemplate<String> |
StringsGenerator.strings(DataSource<Character> characters,
int length)
Generates random strings.
|
| Constructor and Description |
|---|
CharactersGenerator(DataSource<Integer> scalarGenerator) |
StringsGenerator(DataSource<Character> characters) |
StringsGenerator(DataSource<Character> characters,
DataSource<Integer> length) |
StringsGenerator(DataSource<Character> characters,
DataSource<Integer> length) |
StringsGenerator(DataSource<Character> characters,
int length) |
| Modifier and Type | Class and Description |
|---|---|
class |
ConstantValue<T> |
class |
EmptySequence<T> |
class |
ItemsSequence<T> |
static class |
ItemsSequence.FromArray<T> |
static class |
ItemsSequence.FromCollection<T> |
static class |
ItemsSequence.FromRAList<T> |
class |
PermutationsGenerator<T> |
| Modifier and Type | Class and Description |
|---|---|
class |
AbstractValues<T>
Base class for
Values implementations. |
class |
EagerValues<T>
Values immediately fetched from a generator.
|
class |
LazyValues<T>
Values fetched from generators on demand.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
LazyValues._add(DataSource<? extends T> value) |
protected void |
LazyValues._add(DataSource<? extends T> value,
int n) |
protected void |
EagerValues._add(DataSource<? extends T> values,
int length) |
static <T> EagerValues<T> |
EagerValues.all(DataSource<T> values)
Fetches elements from
values,
until it throws a GeneratorException. |
static <T> LazyValues<T> |
LazyValues.any(Generator<Integer> n,
DataSource<? extends T> values)
Fetches up to
n elements from values. |
static <T> LazyValues<T> |
LazyValues.any(int n,
DataSource<? extends T> values)
Fetches up to
n elements from values. |
static <T> EagerValues<T> |
EagerValues.first(Generator<Integer> n,
DataSource<T> values)
Fetches the next
n elements from values. |
static <T> EagerValues<T> |
EagerValues.first(int n,
DataSource<T> values)
Fetches the next
n elements from values. |
static <T> EagerValues<T> |
EagerValues.firstOf(DataSource<T> values)
Fetches the next element from
values. |
static <T> EagerValues<T> |
EagerValues.next(Generator<Integer> n,
DataSource<T> values)
Fetches the next
n elements from values. |
static <T> EagerValues<T> |
EagerValues.next(int n,
DataSource<T> values)
Fetches the next
n elements from values. |
LazyValues<T> |
LazyValues.then(DataSource<? extends T> moreValues) |
LazyValues<T> |
EagerValues.then(DataSource<? extends T> moreValues) |
FlValues<T> |
AbstractValues.then(Generator<Integer> n,
DataSource<? extends T> moreValues) |
LazyValues<T> |
LazyValues.then(int n,
DataSource<? extends T> moreValues) |
EagerValues<T> |
EagerValues.then(int n,
DataSource<? extends T> moreValues) |
LazyValues<T> |
AbstractValues.thenAll(DataSource<? extends T>... moreValues) |
static <T> LazyValues<T> |
LazyValues.unbound(DataSource<? extends T> values)
Fetches elements from
values. |
| Constructor and Description |
|---|
EagerValues(Class<T> valueType,
Collection<T> initial,
DataSource<? extends T> values,
int length) |
EagerValues(DataSource<? extends T> values,
int length) |
LazyValues(Collection<? extends T> initial,
DataSource<? extends T> values) |
LazyValues(Collection<? extends T> initial,
DataSource<? extends T> values,
Collection<? extends LazyValues.Fetch<T>> moreValues,
int n) |
LazyValues(Collection<? extends T> initial,
DataSource<? extends T> values,
int n) |
LazyValues(DataSource<? extends T> values) |
LazyValues(DataSource<? extends T> values,
int n) |
Copyright © 2019. All rights reserved.