RandomGeneratorProvider

class RandomGeneratorProvider(val generator: RandomGenerator) : UniformRandomProvider(source)

Implements UniformRandomProvider by delegating all operations to RandomGenerator.

Constructors

Link copied to clipboard
constructor(generator: RandomGenerator)

Functions

Link copied to clipboard
open override fun nextBoolean(): Boolean

Generates a Boolean value.

Link copied to clipboard
open override fun nextBytes(bytes: ByteArray)
open override fun nextBytes(bytes: ByteArray, start: Int, len: Int)

Generates Byte values and places them into a user-supplied array.

Link copied to clipboard
open override fun nextDouble(): Double

Generates a Double value between 0 and 1.

Link copied to clipboard
open override fun nextFloat(): Float

Generates a Float value between 0 and 1.

Link copied to clipboard
open override fun nextInt(): Int

Generates an Int value.

open override fun nextInt(n: Int): Int

Generates an Int value between 0 (inclusive) and the specified value (exclusive).

Link copied to clipboard
open override fun nextLong(): Long

Generates a Long value.

open override fun nextLong(n: Long): Long

Generates a Long value between 0 (inclusive) and the specified value (exclusive).

Properties

Link copied to clipboard

the underlying RandomGenerator object.