Class Long2LongArray
java.lang.Object
org.apache.commons.rng.simple.internal.Long2LongArray
- All Implemented Interfaces:
Seed2ArrayConverter<Long,
,long[]> SeedConverter<Long,
long[]>
Uses a
Long
value to seed a
SplitMix64
RNG and
create a long[]
with the requested number of random
values.- Since:
- 1.0
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
size
private final int sizeSize of the output array.
-
-
Constructor Details
-
Long2LongArray
public Long2LongArray(int size) Create an instance.- Parameters:
size
- Size of the output array.
-
-
Method Details
-
convert
Converts seed from input type to output type.- Specified by:
convert
in interfaceSeedConverter<Long,
long[]> - Parameters:
seed
- Original seed value.- Returns:
- the converted seed value.
-
convert
Converts seed from input type to output type. The output type is expected to be an array.- Specified by:
convert
in interfaceSeed2ArrayConverter<Long,
long[]> - Parameters:
seed
- Original seed value.outputSize
- Output size.- Returns:
- the converted seed value.
- Since:
- 1.3
-