The distribution function uniform_int models a . More...
#include <uniform_int.hpp>


Classes | |
| class | param_type | 
Public Types | |
| typedef IntType | input_type | 
| typedef IntType | result_type | 
Public Member Functions | |
| uniform_int (IntType min_arg=0, IntType max_arg=9) | |
| Constructs a uniform_int object.  More... | |
| uniform_int (const param_type &parm) | |
| Constructs a uniform_int distribution from its parameters.  More... | |
| param_type | param () const | 
| Returns the parameters of the distribution.  More... | |
| void | param (const param_type &parm) | 
| Sets the parameters of the distribution.  More... | |
| template<class Engine > | |
| IntType | operator() (Engine &eng) const | 
| template<class Engine > | |
| IntType | operator() (Engine &eng, const param_type &parm) const | 
| template<class Engine > | |
| IntType | operator() (Engine &eng, IntType n) const | 
| IntType min | BOOST_PREVENT_MACRO_SUBSTITUTION () const | 
| Returns the minimum value of the distribution.  More... | |
| IntType max | BOOST_PREVENT_MACRO_SUBSTITUTION () const | 
| Returns the maximum value of the distribution.  More... | |
| IntType | a () const | 
| Returns the minimum value of the distribution.  More... | |
| IntType | b () const | 
| Returns the maximum value of the distribution.  More... | |
| void | param (const param_type &parm) | 
| Sets the parameters of the distribution.  More... | |
| void | reset () | 
| Effects: Subsequent uses of the distribution do not depend on values produced by any engine prior to invoking reset.  More... | |
| template<class Engine > | |
| result_type | operator() (Engine &eng, const param_type &parm) const | 
| Returns an integer uniformly distributed in the range [param.a(), param.b()].  More... | |
| BOOST_RANDOM_DETAIL_OSTREAM_OPERATOR (os, uniform_int_distribution, ud) | |
Writes the distribution to a std::ostream.  More... | |
| BOOST_RANDOM_DETAIL_ISTREAM_OPERATOR (is, uniform_int_distribution, ud) | |
Reads the distribution from a std::istream.  More... | |
| BOOST_RANDOM_DETAIL_EQUALITY_OPERATOR (uniform_int_distribution, lhs, rhs) | |
| Returns true if the two distributions will produce identical sequences of values given equal generators.  More... | |
The distribution function uniform_int models a .
On each invocation, it returns a random integer value uniformly distributed in the set of integer numbers {min, min+1, min+2, ..., max}.
The template parameter IntType shall denote an integer-like value type.
This class is deprecated. Please use uniform_int_distribution in new code. 
      
  | 
  inherited | 
      
  | 
  inherited | 
      
  | 
  inlineexplicit | 
Constructs a uniform_int object.
min and max are the parameters of the distribution.
Requires: min <= max
      
  | 
  inlineexplicit | 
Constructs a uniform_int distribution from its parameters.
      
  | 
  inlineinherited | 
Returns the minimum value of the distribution.
Referenced by boost::uniform_int< IntType >::param().
      
  | 
  inlineinherited | 
Returns the maximum value of the distribution.
Referenced by boost::uniform_int< IntType >::param().
      
  | 
  inlineinherited | 
Returns the minimum value of the distribution.
      
  | 
  inlineinherited | 
Returns the maximum value of the distribution.
      
  | 
  inlineinherited | 
Returns true if the two distributions will produce identical sequences of values given equal generators.
      
  | 
  inlineinherited | 
Reads the distribution from a std::istream. 
      
  | 
  inlineinherited | 
Writes the distribution to a std::ostream. 
      
  | 
  inline | 
      
  | 
  inline | 
      
  | 
  inline | 
References BOOST_ASSERT.
      
  | 
  inlineinherited | 
Returns an integer uniformly distributed in the range [param.a(), param.b()].
References boost::random::uniform_int_distribution< IntType >::param_type::a(), boost::random::uniform_int_distribution< IntType >::param_type::b(), and boost::random::detail::generate_uniform_int().
      
  | 
  inline | 
Returns the parameters of the distribution.
References boost::random::uniform_int_distribution< IntType >::a(), and boost::random::uniform_int_distribution< IntType >::b().
      
  | 
  inline | 
Sets the parameters of the distribution.
References boost::random::uniform_int_distribution< IntType >::param().
      
  | 
  inlineinherited | 
Sets the parameters of the distribution.
References boost::random::uniform_int_distribution< IntType >::param_type::a(), and boost::random::uniform_int_distribution< IntType >::param_type::b().
      
  | 
  inlineinherited | 
Effects: Subsequent uses of the distribution do not depend on values produced by any engine prior to invoking reset.