RandomX extension

on

Methods

decimals(int count, {num scale = 1, num min = 0}) List<double>
generates a list containing count random doubles whose values fall between min (inclusive) and scale+min (inclusive)
elements<T>(List<T> sourceElements, {int? count, bool unique = false}) List<T>
Plucks a random subset of elements from the given sourceElements
int({int min = 0, int? max, bool only32bit = false, bool only64bit = false}) int
generates a random integer whose value falls between min (inclusive) and max (exclusive)
int32({int min = 0, int? max}) → Int32
generates a random Int32 whose value falls between min (inclusive) and max (exclusive)
int32s(int count, {int min = 0, int? max}) List<Int32>
generates a list containing count random Int32s whose values fall between min (inclusive) and max (exclusive) if passed, the value of min must be limited to a 32-bit max value; passing a number outside the 32-bit space will throw an ArgumentError
int64({int min = 0, int? max}) → Int64
generates a random Int64 whose value falls between min (inclusive) and max (exclusive)
int64s(int count, {int min = 0, int? max}) List<Int64>
generates a list containing count random Int64s whose values fall between min (inclusive) and max (exclusive)
ints(int count, {int min = 0, int? max, bool only32bit = false, bool only64bit = false}) List<int>
generates a list containing count random integers whose values fall between min (inclusive) and max (exclusive)
strings(int count, int maxLength, {int minLength = 1}) List<String>
generates a list containing count random alphanumeric strings, each with length between minLength (inclusive) to maxLength (inclusive)