MCKL
Monte Carlo Kernel Library
Classes | Public Types | Public Member Functions | Friends | List of all members
mckl::SamplingDistribution< IntType > Class Template Reference

Drawing a subset without replacement. More...

#include <mckl/random/internal/common.hpp>

Classes

class  param_type
 

Public Types

using distribution_type = SamplingDistribution< IntType >
 
using result_type = IntType
 

Public Member Functions

 SamplingDistribution (result_type n=1, result_type m=1)
 
result_type m () const
 
void max (result_type *r) const
 
void min (result_type *r) const
 
result_type n () const
 
template<typename RNGType >
void operator() (RNGType &rng, result_type *r) const
 

Friends

bool operator!= (const distribution_type &dist1, const distribution_type &dist2)
 
template<typename CharT , typename Traits >
std::basic_ostream< CharT, Traits > & operator<< (std::basic_ostream< CharT, Traits > &os, const distribution_type &dist)
 
bool operator== (const distribution_type &dist1, const distribution_type &dist2)
 
template<typename CharT , typename Traits >
std::basic_istream< CharT, Traits > & operator>> (std::basic_istream< CharT, Traits > &is, distribution_type &dist)
 

Detailed Description

template<typename IntType>
class mckl::SamplingDistribution< IntType >

Drawing a subset without replacement.

Definition at line 1105 of file random/internal/common.hpp.

Member Typedef Documentation

◆ distribution_type

template<typename IntType >
using mckl::SamplingDistribution< IntType >::distribution_type = SamplingDistribution<IntType>

Definition at line 49 of file sampling_distribution.hpp.

◆ result_type

template<typename IntType >
using mckl::SamplingDistribution< IntType >::result_type = IntType

Definition at line 48 of file sampling_distribution.hpp.

Constructor & Destructor Documentation

◆ SamplingDistribution()

template<typename IntType >
mckl::SamplingDistribution< IntType >::SamplingDistribution ( result_type  n = 1,
result_type  m = 1 
)
inlineexplicit

Definition at line 120 of file sampling_distribution.hpp.

Member Function Documentation

◆ m()

template<typename IntType >
result_type mckl::SamplingDistribution< IntType >::m ( ) const
inline

Definition at line 139 of file sampling_distribution.hpp.

◆ max()

template<typename IntType >
void mckl::SamplingDistribution< IntType >::max ( result_type r) const
inline

Definition at line 131 of file sampling_distribution.hpp.

◆ min()

template<typename IntType >
void mckl::SamplingDistribution< IntType >::min ( result_type r) const
inline

Definition at line 125 of file sampling_distribution.hpp.

◆ n()

template<typename IntType >
result_type mckl::SamplingDistribution< IntType >::n ( ) const
inline

Definition at line 137 of file sampling_distribution.hpp.

◆ operator()()

template<typename IntType >
template<typename RNGType >
void mckl::SamplingDistribution< IntType >::operator() ( RNGType &  rng,
result_type r 
) const
inline

Definition at line 142 of file sampling_distribution.hpp.

Friends And Related Function Documentation

◆ operator!=

template<typename IntType >
bool operator!= ( const distribution_type dist1,
const distribution_type dist2 
)
friend

Definition at line 170 of file sampling_distribution.hpp.

◆ operator<<

template<typename IntType >
template<typename CharT , typename Traits >
std::basic_ostream<CharT, Traits>& operator<< ( std::basic_ostream< CharT, Traits > &  os,
const distribution_type dist 
)
friend

Definition at line 177 of file sampling_distribution.hpp.

◆ operator==

template<typename IntType >
bool operator== ( const distribution_type dist1,
const distribution_type dist2 
)
friend

Definition at line 164 of file sampling_distribution.hpp.

◆ operator>>

template<typename IntType >
template<typename CharT , typename Traits >
std::basic_istream<CharT, Traits>& operator>> ( std::basic_istream< CharT, Traits > &  is,
distribution_type dist 
)
friend

Definition at line 186 of file sampling_distribution.hpp.