32 #ifndef CLASSES_RANDOM_DEVICES_H_ 33 #define CLASSES_RANDOM_DEVICES_H_ 49 class RandomDevices final :
public internal::Singleton<RandomDevices>
52 friend class internal::Singleton<RandomDevices>;
54 std::random_device rd_;
61 std::mt19937& get_prng() {
return prng_; }
68 std::istream& load(std::istream& is) {
return is >> prng_; }
75 std::ostream& save(std::ostream& os)
const {
return os << prng_; }
81 RandomDevices() : rd_{}, prng_{rd_()} {}
86 ~RandomDevices() =
default;
Quantum++ main namespace.
Definition: circuits.h:35