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


Struct template value_type

boost::histogram::axis::traits::value_type — Value type for axis type.


// In header: <boost/histogram/axis/traits.hpp>

template<typename Axis> 
struct value_type {


Doxygen does not render this well. This is a meta-function (template alias), it accepts an axis type and returns the value type.

The value type is deduced from the argument of the Axis::index method. Const references are decayed to the their value types, for example, the type deduced forAxis::index(const int&) isint.

The deduction always succeeds if the axis type models the Axis concept correctly. Errors come from violations of the concept, in particular, an index method that is templated or overloaded is not allowed.

Template Parameters

  1. typename Axis

    axis type.