|
Lightweight 0.20260213.0
|
Seeded random number generator wrapper for deterministic generation. More...
#include <DataGenerator.hpp>
Public Member Functions | |
| SeededRandom (uint64_t seed) | |
| int64_t | NextInt (int64_t min, int64_t max) |
| Generates a random integer in range [min, max]. | |
| double | NextDouble (double min, double max) |
| Generates a random double in range [min, max). | |
| template<typename T > | |
| T const & | Pick (std::vector< T > const &items) |
| Picks a random element from a vector. | |
| bool | NextBool (double probabilityTrue=0.5) |
| Generates a random boolean with given probability of true. | |
| std::string | GenerateText (size_t targetSize) |
| Generates random text of approximately the given size. | |
| std::vector< uint8_t > | GenerateBinaryData (size_t targetSize) |
| Generates pseudo-random binary data of the given size. | |
| std::string | GenerateJson (size_t targetSize) |
| Generates a pseudo-random JSON object of approximately the given size. | |
| std::string | GenerateEmail (int64_t userId) |
| Generates a random email address. | |
| std::string | GenerateProductName (int64_t productId) |
| Generates a random product name. | |
| std::string | GenerateAddressJson () |
| Generates random address JSON. | |
Seeded random number generator wrapper for deterministic generation.
Definition at line 65 of file DataGenerator.hpp.
|
inline |
Picks a random element from a vector.
Definition at line 78 of file DataGenerator.hpp.
References NextInt().