bcds.tools.random
Class RndGenBase

java.lang.Object
  extended by bcds.tools.random.RndGenBase
Direct Known Subclasses:
RndArea, RndExp, RndLogNormal, RndNormal, RndPareto, RndUnif

public class RndGenBase
extends java.lang.Object

Base class for RndGen. By default, the randomness source an instance of Java.util.Random.

Author:
Juan Segovia S.

Constructor Summary
RndGenBase()
          Default constructor that instantiates a java.util.Random as its source of random numbers.
RndGenBase(java.util.Random rnd)
          Constructor that uses rnd as the randomness source.
 
Method Summary
 java.util.Random getRandomGen()
          Returns the current randomness source.
 void setRandomGen(java.util.Random rnd)
          Sets the the randomness source for this object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RndGenBase

public RndGenBase()
Default constructor that instantiates a java.util.Random as its source of random numbers.


RndGenBase

public RndGenBase(java.util.Random rnd)
Constructor that uses rnd as the randomness source.

Method Detail

setRandomGen

public void setRandomGen(java.util.Random rnd)
Sets the the randomness source for this object.


getRandomGen

public java.util.Random getRandomGen()
Returns the current randomness source.