C# Class RandomOps.Switcher

Randomly switch between different RNGs. Thread-safe if RNGs are thread-safe.
This basically just implements the SelectRand() method from the RandMulti-class.
Inheritance: Multi
显示文件 Open project: DanWBR/dwsim3

Public Methods

Method Description
Switcher ( Random randSwitch, Random rands )

Constructs the RNG-object from other RNGs.

Protected Methods

Method Description
SelectRand ( ) : int

Determine which RNG in RandMulti to use.

Method Details

SelectRand() protected method

Determine which RNG in RandMulti to use.
protected SelectRand ( ) : int
return int

Switcher() public method

Constructs the RNG-object from other RNGs.
public Switcher ( Random randSwitch, Random rands )
randSwitch Random The RNG that will be used to determine switching.
rands Random The RNGs to switch between.