Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for a snapshot of the master branch, built from commit d0783280b8.
PrevUpHomeNext

Class template xrange_t

boost::unit_test::data::monomorphic::xrange_t — Generator for the range sequences.

Synopsis

// In header: <boost/test/data/monomorphic/generators/xrange.hpp>

template<typename SampleType, typename StepType = SampleType> 
class xrange_t {
public:
  // types
  typedef SampleType sample;

  // public member functions
  xrange_t(SampleType const &, StepType const &, data::size_t);
  data::size_t capacity() const;
  SampleType next();
  void reset();
};

Description

This class implements the generator concept (see boost::unit_test::data::monomorphic::generated_by) for implementing a range like sequence of numbers.

xrange_t public member functions

  1. xrange_t(SampleType const & begin_, StepType const & step_, 
             data::size_t size_);
  2. data::size_t capacity() const;
  3. SampleType next();
  4. void reset();

PrevUpHomeNext