public final class ProviderBuilder extends Object
It uses reflection to find the factory method of the RNG implementation, and performs seed type conversions.
| Modifier and Type | Class and Description |
|---|---|
static class |
ProviderBuilder.RandomSourceInternal
Identifiers of the generators.
|
| Modifier and Type | Method and Description |
|---|---|
static RestorableUniformRandomProvider |
create(ProviderBuilder.RandomSourceInternal source)
Creates a RNG instance.
|
static RestorableUniformRandomProvider |
create(ProviderBuilder.RandomSourceInternal source,
Object seed,
Object[] args)
Creates a RNG instance.
|
public static RestorableUniformRandomProvider create(ProviderBuilder.RandomSourceInternal source)
source - RNG specification.IllegalArgumentException - if argument data to initialize the
generator implemented by the given source is missing.public static RestorableUniformRandomProvider create(ProviderBuilder.RandomSourceInternal source, Object seed, Object[] args)
source - RNG specification.seed - Seed value. It can be null (in which case a
random value will be used).args - Additional arguments to the implementation's constructor.UnsupportedOperationException - if the seed type is invalid.IllegalArgumentException - if argument data to initialize the
generator implemented by the given source is invalid.Copyright © 2016–2022 The Apache Software Foundation. All rights reserved.