public class SecureThreadedRandom
extends java.security.SecureRandom
| Modifier and Type | Field and Description |
|---|---|
protected java.security.SecureRandom[] |
prngs
The random number generators.
|
protected int |
threadingmask
Mask for distributing threads.
|
| Constructor and Description |
|---|
SecureThreadedRandom()
Creates the wrapper.
|
| Modifier and Type | Method and Description |
|---|---|
byte[] |
generateSeed(int numbytes)
Generates a seed value from OS source.
|
boolean |
nextBoolean()
Wrapper method.
|
void |
nextBytes(byte[] bytes)
Wrapper method.
|
double |
nextDouble()
Wrapper method.
|
float |
nextFloat()
Wrapper method.
|
double |
nextGaussian()
Wrapper method.
|
int |
nextInt()
Wrapper method.
|
int |
nextInt(int bound)
Wrapper method.
|
long |
nextLong()
Wrapper method.
|
void |
setSeed(long seed)
Wrapper method.
|
getAlgorithm, getInstance, getInstance, getInstance, getInstanceStrong, getProvider, getSeed, next, setSeedprotected java.security.SecureRandom[] prngs
protected int threadingmask
public boolean nextBoolean()
nextBoolean in class java.util.Randompublic void nextBytes(byte[] bytes)
nextBytes in class java.security.SecureRandompublic double nextDouble()
nextDouble in class java.util.Randompublic float nextFloat()
nextFloat in class java.util.Randompublic double nextGaussian()
nextGaussian in class java.util.Randompublic int nextInt()
nextInt in class java.util.Randompublic int nextInt(int bound)
nextInt in class java.util.Randompublic long nextLong()
nextLong in class java.util.Randompublic byte[] generateSeed(int numbytes)
generateSeed in class java.security.SecureRandompublic void setSeed(long seed)
setSeed in class java.security.SecureRandom