Package org.apache.commons.rng.simple
Class ThreadLocalRandomSource.ThreadLocalRng
java.lang.Object
java.lang.ThreadLocal<UniformRandomProvider>
org.apache.commons.rng.simple.ThreadLocalRandomSource.ThreadLocalRng
- Enclosing class:
ThreadLocalRandomSource
private static class ThreadLocalRandomSource.ThreadLocalRng
extends ThreadLocal<UniformRandomProvider>
Extend the
ThreadLocal to allow creation of the desired RandomSource.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class java.lang.ThreadLocal
get, remove, set, withInitial
-
Field Details
-
source
The source.
-
-
Constructor Details
-
ThreadLocalRng
ThreadLocalRng(RandomSource source) Create a new instance.- Parameters:
source- the source
-
-
Method Details
-
initialValue
- Overrides:
initialValuein classThreadLocal<UniformRandomProvider>
-