#ifndef RANDOM_BASE_2019_01_24_H #define RANDOM_BASE_2019_01_24_H #include #include #if(__cplusplus >= 201703L) namespace al::crypto::random { #else namespace al { namespace crypto { namespace random { #endif template class random_base { public: using result_type = ResultType; using internal_type = InternalType; virtual ~random_base() = default; virtual auto operator()() -> result_type = 0; static auto (min)() -> result_type { return (std::numeric_limits::min)(); } static auto (max)() -> result_type { return (std::numeric_limits::max)(); } protected: random_base() = default; explicit random_base(const internal_type) { } // NOLINT(hicpp-named-parameter,readability-named-parameter) random_base(const random_base&) = default; random_base(random_base&&) noexcept = default; auto operator=(const random_base&) -> random_base& = default; auto operator=(random_base&&) noexcept -> random_base& = default; }; #if(__cplusplus >= 201703L) } // namespace al::crypto::random #else } // namespace random } // namespace crypto } // namespace al #endif #endif // RANDOM_BASE_2019_01_24_H