java.lang.Object
de.grogra.blocks.arrangeBlock.SeedGenerator
- All Implemented Interfaces:
DiscreteGenerator
,Seedable
A SeedGenerator is a DiscreteGenerator which produces well-spaced seeds
according to its spacing attribute. It relies on a
RandomGenerator
-
Constructor Summary
-
Method Summary
-
Constructor Details
-
SeedGenerator
public SeedGenerator() -
SeedGenerator
public SeedGenerator(long seed, int spacing)
-
-
Method Details
-
setSeed
public void setSeed(long seed) Description copied from interface:Seedable
Set the random number generator's seed. -
getSeed
public long getSeed()Description copied from interface:Seedable
Get the random number generator's seed. -
reseed
public void reseed()Description copied from interface:Seedable
Get another seed well-spaced (from the defaultSeedGenerator
) -
sample
public long sample()- Specified by:
sample
in interfaceDiscreteGenerator
-