RandomObj

trait RandomObj[T <: Exec[T]] extends Random[T] with Mutable[T]

A transactional pseudo-random number generator which behaves numerically like java.util.Random.

Companion
object
trait Mutable[T]
trait Disposable[T]
trait Writable
trait Identified[T]
trait Random[T]
class Object
trait Matchable
class Any

Value members

Abstract methods

def copy[Out <: Exec[LazyRef(...)]]()(implicit tx: T, txOut: Out): RandomObj[Out]

Inherited methods

def dispose()(implicit tx: T): Unit
Inherited from
Disposable
override
def equals(that: Any): Boolean
Definition Classes
Identified -> Any
Inherited from
Identified
override
def hashCode: Int
Definition Classes
Identified -> Any
Inherited from
Identified
def id: Ident[T]
Inherited from
Identified
def nextBoolean()(implicit tx: T): Boolean

Generates a random Boolean value.

Generates a random Boolean value.

Inherited from
Random
def nextDouble()(implicit tx: T): Double

Generates a random Double value, uniformly distributed between 0.0 (inclusive) and 1.0 (exclusive).

Generates a random Double value, uniformly distributed between 0.0 (inclusive) and 1.0 (exclusive).

Inherited from
Random
def nextFloat()(implicit tx: T): Float

Generates a random Float value, uniformly distributed between 0.0f (inclusive) and 1.0f (exclusive).

Generates a random Float value, uniformly distributed between 0.0f (inclusive) and 1.0f (exclusive).

Inherited from
Random
def nextInt(n: Int)(implicit tx: T): Int

Generates a random Int value in the range of 0 (inclusive) until the specified value n (exclusive).

Generates a random Int value in the range of 0 (inclusive) until the specified value n (exclusive).

Inherited from
Random
def nextInt()(implicit tx: T): Int

Generates a random Int value in the range Int.MinValue to Int.MaxValue.

Generates a random Int value in the range Int.MinValue to Int.MaxValue.

Inherited from
Random
def nextLong()(implicit tx: T): Long

Generates a random Long value in the range Long.MinValue to Long.MaxValue.

Generates a random Long value in the range Long.MinValue to Long.MaxValue.

WARNING: Because it uses the same algorithm as java.util.Random, with a seed of only 48 bits, this function will not return all possible long values!

Inherited from
Random
def rawSeed(implicit tx: T): Long
Inherited from
Random
def rawSeed_=(seed: Long)(implicit tx: T): Unit

Resets the internal seed value to the given argument. This is a raw seed value as obtained from getRawSeed. For user operation, use setSeed instead, which further scrambles the seed value.

Resets the internal seed value to the given argument. This is a raw seed value as obtained from getRawSeed. For user operation, use setSeed instead, which further scrambles the seed value.

Inherited from
Random
def setSeed(seed: Long)(implicit tx: T): Unit

Resets the internal seed value to the given argument.

Resets the internal seed value to the given argument.

Inherited from
Random
def write(out: DataOutput): Unit
Inherited from
Writable