nextBytes

open override fun nextBytes(bytes: ByteArray)(source)

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

The number of random bytes produced is equal to the length of the byte array.

Parameters

bytes

byte array in which to put the random bytes.


open override fun nextBytes(bytes: ByteArray, start: Int, len: Int)(source)

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

The array is filled with bytes extracted from random integers. This implies that the number of random bytes generated may be larger than the length of the byte array.

Parameters

bytes

the array in which to put the generated bytes.

start

the index at which to start inserting the generated bytes.

len

the number of bytes to insert.