public class Uniform extends AbstractRandom
Constructor and Description |
---|
Uniform()
Creates a new instance based on the current simulator's random generator.
|
Uniform(double max)
Creates a new instance based on the current simulator's random generator.
|
Uniform(double min,
double max)
Creates a new instance based on the current simulator's random generator.
|
Uniform(double min,
double max,
Random generator) |
Uniform(double max,
Random generator)
Equivalent to
Uniform(generator, 0.0d, max) . |
Uniform(Random generator)
Equivalent to
Uniform(generator, 0.0d, Double.MAX_VALUE) . |
Modifier and Type | Method and Description |
---|---|
boolean |
nextBoolean() |
byte |
nextByte() |
double |
nextDouble() |
float |
nextFloat() |
int |
nextInt() |
long |
nextLong() |
short |
nextShort() |
public Uniform(double min, double max, Random generator)
min
- inclusivemax
- inclusivegenerator
- public Uniform(double min, double max)
Uniform(double, double, Random)
public Uniform(double max, Random generator)
Uniform(generator, 0.0d, max)
.max
- inclusivegenerator
- public Uniform(double max)
Uniform(double, Random)
public Uniform(Random generator)
Uniform(generator, 0.0d, Double.MAX_VALUE)
.generator
- public Uniform()
Uniform(double, double, Random)
public boolean nextBoolean()
nextBoolean
in interface NumberGenerator
nextBoolean
in class AbstractRandom
public byte nextByte()
nextByte
in interface NumberGenerator
nextByte
in class AbstractRandom
public short nextShort()
nextShort
in interface NumberGenerator
nextShort
in class AbstractRandom
public int nextInt()
nextInt
in interface NumberGenerator
nextInt
in class AbstractRandom
public long nextLong()
nextLong
in interface NumberGenerator
nextLong
in class AbstractRandom
public float nextFloat()
nextFloat
in interface NumberGenerator
nextFloat
in class AbstractRandom
public double nextDouble()
nextDouble
in interface NumberGenerator
nextDouble
in class AbstractRandom