public final class MyRandom
extends java.lang.Object
Constructor and Description |
---|
MyRandom() |
MyRandom(java.util.Random rand) |
Modifier and Type | Method and Description |
---|---|
java.util.Random |
getRandSource() |
int |
nextInt(int max) |
long |
nextLong() |
void |
setSeed(long randomSeed) |
void |
setSeed(long randomSeed,
boolean bReplaceSeed)
Reseeds the random number generator.
|
public int nextInt(int max)
public java.util.Random getRandSource()
public void setSeed(long randomSeed)
public void setSeed(long randomSeed, boolean bReplaceSeed)
randomSeed
- the new seed, which either supplements or replaces the current seedbReplaceSeed
- if true the given seed will completely replace the current seed, otherwise it will just supplement itpublic long nextLong()
Copyright © 2023. All rights reserved.