Tatooine
Public Types | Public Member Functions | Private Attributes | List of all members
tatooine::random::uniform< ValueType, Engine > Struct Template Reference

#include <random.h>

Collaboration diagram for tatooine::random::uniform< ValueType, Engine >:
[legend]

Public Types

using engine_type = Engine
 
using real_type = ValueType
 
using distribution_type = std::conditional_t< is_floating_point< ValueType >, std::uniform_real_distribution< ValueType >, std::uniform_int_distribution< ValueType > >
 

Public Member Functions

 uniform ()
 
 uniform (const uniform &)=default
 
 uniform (uniform &&) noexcept=default
 
auto operator= (const uniform &) noexcept -> uniform &=default
 
auto operator= (uniform &&) noexcept -> uniform &=default
 
 ~uniform ()=default
 
 uniform (ValueType const min, ValueType const max)
 
template<convertible_to< Engine > EngineArg>
 uniform (ValueType const min, ValueType const max, EngineArg &&eng)
 
template<convertible_to< Engine > EngineArg>
 uniform (EngineArg &&eng)
 
auto operator() ()
 
auto engine () const -> auto const &
 
auto engine () -> auto &
 
auto distribution () const -> auto const &
 
auto distribution () -> auto &
 

Private Attributes

engine_type m_engine
 
distribution_type m_distribution
 

Member Typedef Documentation

◆ distribution_type

template<typename ValueType , typename Engine = std::mt19937_64>
using tatooine::random::uniform< ValueType, Engine >::distribution_type = std::conditional_t<is_floating_point<ValueType>, std::uniform_real_distribution<ValueType>, std::uniform_int_distribution<ValueType> >

◆ engine_type

template<typename ValueType , typename Engine = std::mt19937_64>
using tatooine::random::uniform< ValueType, Engine >::engine_type = Engine

◆ real_type

template<typename ValueType , typename Engine = std::mt19937_64>
using tatooine::random::uniform< ValueType, Engine >::real_type = ValueType

Constructor & Destructor Documentation

◆ uniform() [1/6]

template<typename ValueType , typename Engine = std::mt19937_64>
tatooine::random::uniform< ValueType, Engine >::uniform ( )
inline

◆ uniform() [2/6]

template<typename ValueType , typename Engine = std::mt19937_64>
tatooine::random::uniform< ValueType, Engine >::uniform ( const uniform< ValueType, Engine > &  )
default

◆ uniform() [3/6]

template<typename ValueType , typename Engine = std::mt19937_64>
tatooine::random::uniform< ValueType, Engine >::uniform ( uniform< ValueType, Engine > &&  )
defaultnoexcept

◆ ~uniform()

template<typename ValueType , typename Engine = std::mt19937_64>
tatooine::random::uniform< ValueType, Engine >::~uniform ( )
default

◆ uniform() [4/6]

template<typename ValueType , typename Engine = std::mt19937_64>
tatooine::random::uniform< ValueType, Engine >::uniform ( ValueType const  min,
ValueType const  max 
)
inline

◆ uniform() [5/6]

template<typename ValueType , typename Engine = std::mt19937_64>
template<convertible_to< Engine > EngineArg>
tatooine::random::uniform< ValueType, Engine >::uniform ( ValueType const  min,
ValueType const  max,
EngineArg &&  eng 
)
inline

◆ uniform() [6/6]

template<typename ValueType , typename Engine = std::mt19937_64>
template<convertible_to< Engine > EngineArg>
tatooine::random::uniform< ValueType, Engine >::uniform ( EngineArg &&  eng)
inline

Member Function Documentation

◆ distribution() [1/2]

template<typename ValueType , typename Engine = std::mt19937_64>
auto tatooine::random::uniform< ValueType, Engine >::distribution ( ) -> auto&
inline

◆ distribution() [2/2]

template<typename ValueType , typename Engine = std::mt19937_64>
auto tatooine::random::uniform< ValueType, Engine >::distribution ( ) const -> auto const&
inline

◆ engine() [1/2]

template<typename ValueType , typename Engine = std::mt19937_64>
auto tatooine::random::uniform< ValueType, Engine >::engine ( ) -> auto&
inline

◆ engine() [2/2]

template<typename ValueType , typename Engine = std::mt19937_64>
auto tatooine::random::uniform< ValueType, Engine >::engine ( ) const -> auto const&
inline

◆ operator()()

template<typename ValueType , typename Engine = std::mt19937_64>
auto tatooine::random::uniform< ValueType, Engine >::operator() ( )
inline

◆ operator=() [1/2]

template<typename ValueType , typename Engine = std::mt19937_64>
auto tatooine::random::uniform< ValueType, Engine >::operator= ( const uniform< ValueType, Engine > &  ) -> uniform &=default
defaultnoexcept

◆ operator=() [2/2]

template<typename ValueType , typename Engine = std::mt19937_64>
auto tatooine::random::uniform< ValueType, Engine >::operator= ( uniform< ValueType, Engine > &&  ) -> uniform &=default
defaultnoexcept

Member Data Documentation

◆ m_distribution

template<typename ValueType , typename Engine = std::mt19937_64>
distribution_type tatooine::random::uniform< ValueType, Engine >::m_distribution
private

◆ m_engine

template<typename ValueType , typename Engine = std::mt19937_64>
engine_type tatooine::random::uniform< ValueType, Engine >::m_engine
private

The documentation for this struct was generated from the following file: