last update 20 Sep 2009 |
#include <cvrRandomDistribution.h>
Public Member Functions | |
rndStochastic () | |
virtual | ~rndStochastic () |
virtual uint32 | draw () |
virtual void | setSeed (const uint32 seed) |
uint32 | max () const |
bool | setDevice (const std::string &device) |
virtual bool | write (ioHandler &handler, const bool complete=true) const |
virtual bool | read (ioHandler &handler, const bool complete=true) |
Protected Attributes | |
FILE * | handler_ |
cvr::randomDistribution::randomDistribution::rndStochastic::rndStochastic | ( | ) |
Constructor.
virtual cvr::randomDistribution::randomDistribution::rndStochastic::~rndStochastic | ( | ) | [virtual] |
Destructor.
virtual uint32 cvr::randomDistribution::randomDistribution::rndStochastic::draw | ( | ) | [virtual] |
uint32 cvr::randomDistribution::randomDistribution::rndStochastic::max | ( | ) | const [virtual] |
Return the maximal obtainable number (inclusive).
Implements cvr::randomDistribution::randomDistribution::rndBase.
virtual bool cvr::randomDistribution::randomDistribution::rndStochastic::read | ( | ioHandler & | handler, | |
const bool | complete = true | |||
) | [virtual] |
Read the parameters from the given ioHandler.
handler | the ioHandler to be used | |
complete | if true (the default) the enclosing begin/end will be also written, otherwise only the data block will be written. |
Implements cvr::randomDistribution::randomDistribution::rndBase.
bool cvr::randomDistribution::randomDistribution::rndStochastic::setDevice | ( | const std::string & | device | ) |
Set the file device to be used.
virtual void cvr::randomDistribution::randomDistribution::rndStochastic::setSeed | ( | const uint32 | seed | ) | [virtual] |
virtual bool cvr::randomDistribution::randomDistribution::rndStochastic::write | ( | ioHandler & | handler, | |
const bool | complete = true | |||
) | const [virtual] |
Write the parameters in the given ioHandler.
handler | the ioHandler to be used | |
complete | if true (the default) the enclosing begin/end will be also written, otherwise only the data block will be written. |
Implements cvr::randomDistribution::randomDistribution::rndBase.
FILE* cvr::randomDistribution::randomDistribution::rndStochastic::handler_ [protected] |
File handler to the device used to generate random numbers.