trait Random extends Control
A random number generator that can be used for operations such as .until
and .range
.
Example:
val gen = Random() val r100 = gen.until(100) Act( r100, // draw new number between 0 and 99 PrintLn("Random number: " ++ r100.toStr) // print current value )
Linear Supertypes
Ordering
- Alphabetic
- By Inheritance
Inherited
- Random
- Control
- Lazy
- Product
- Equals
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- Protected
Type Members
- abstract type Repr[T <: Txn[T]] <: IControl[T] with lucre.Random[T]
Abstract Value Members
- abstract def canEqual(that: Any): Boolean
- Definition Classes
- Equals
- abstract def mkRepr[T <: Txn[T]](implicit ctx: Context[T], tx: T): Repr[T]
- Attributes
- protected
- Definition Classes
- Lazy
- abstract def productArity: Int
- Definition Classes
- Product
- abstract def productElement(n: Int): Any
- Definition Classes
- Product
Concrete Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native() @HotSpotIntrinsicCandidate()
- def coin[A, B](prob: Ex[A])(implicit num: NumDouble[A] { type Boolean = B }, default: HasDefault[B]): Coin[A, B]
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- final def expand[T <: Txn[T]](implicit ctx: Context[T], tx: T): Repr[T]
- Definition Classes
- Lazy
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @HotSpotIntrinsicCandidate()
- def productElementName(n: Int): String
- Definition Classes
- Product
- def productElementNames: Iterator[String]
- Definition Classes
- Product
- def productIterator: Iterator[Any]
- Definition Classes
- Product
- def productPrefix: String
- Definition Classes
- Product
- def range[A](lo: Ex[A], hi: Ex[A])(implicit num: Num[A]): Range[A]
- final val ref: AnyRef
- Attributes
- protected
- Definition Classes
- Lazy
- Annotations
- @transient()
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def token: AnyRef
- Definition Classes
- Control
- def until[A](hi: Ex[A])(implicit num: Num[A]): Until[A]
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
Deprecated Value Members
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable]) @Deprecated
- Deprecated