Definition of randomness sources. Provided sources are c++ builtin random_device and own semirandom_device. The random device is the best randomness source but its generation is slow. Semirandom device is good enough and it provices random values fast. Given a seed the semirandom device can also provide reproducible sequence any number of times.
More...
#include <random.hpp>
|
static std::random_device & | getRandom () |
| Getter of the singleton random device. More...
|
|
static semirandom_device & | getSemirandom () |
| Getter of the singleton semirandom device. More...
|
|
Definition of randomness sources. Provided sources are c++ builtin random_device and own semirandom_device. The random device is the best randomness source but its generation is slow. Semirandom device is good enough and it provices random values fast. Given a seed the semirandom device can also provide reproducible sequence any number of times.
◆ getRandom()
static std::random_device & ext::random_devices::getRandom |
( |
| ) |
|
|
inlinestatic |
Getter of the singleton random device.
- Returns
- instance of the random device
◆ getSemirandom()
static semirandom_device & ext::random_devices::getSemirandom |
( |
| ) |
|
|
inlinestatic |
Getter of the singleton semirandom device.
- Returns
- instance of the semirandom device
◆ random
std::random_device & ext::random_devices::random = getRandom ( ) |
|
static |
The reference to singleton random device.
◆ semirandom
random_devices::semirandom_device & ext::random_devices::semirandom = getSemirandom ( ) |
|
static |
The reference to singleton semirandom device.
The documentation for this class was generated from the following files: