Lumiera  0.pre.03
»edit your freedom«
Limited< T, max, min, zero > Struct Template Reference

#include "lib/random-draw.hpp"

Description

template<typename T, T max, T min = T(0), T zero = min>
struct lib::Limited< T, max, min, zero >

A Result Value confined into fixed bounds.

Template Parameters
Tunderlying base type (number like)
maxmaximum allowed param value (inclusive)
maxminimum allowed param value (inclusive) - defaults to "zero".
zerothe neutral value in the value range

Definition at line 120 of file random-draw.hpp.

Public Member Functions

template<typename X >
 Limited (X raw)
 
 operator T & ()
 
 operator T const & () const
 

Static Public Member Functions

static constexpr T maxVal ()
 
static constexpr T minVal ()
 
static constexpr T zeroVal ()
 

Public Attributes

val
 
+ Collaboration diagram for Limited< T, max, min, zero >:

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