creativity  v1.3.0
Agent-based model of creativity and piracy
Public Member Functions | Static Public Member Functions | List of all members
creativity::cmdargs::Below< T, upper, denom > Class Template Reference

Validation wrapper for options that have a strict inequality boundary that the value must be below, such as \(v < 3\). More...

#include <creativity/cmdargs/Validation.hpp>

Public Member Functions

 Below (T v)
 Constructor. Throws if v >= upper.
 
- Public Member Functions inherited from creativity::cmdargs::Validation< T >
 Validation (T v)
 Constructs with an initial value.
 
 operator const T & () const
 Implicit conversion to the stored value.
 
virtual ~Validation ()=default
 Virtual destructor.
 

Static Public Member Functions

static std::string validationString ()
 Returns string representation of this validation.
 
- Static Public Member Functions inherited from creativity::cmdargs::Validation< T >
static std::string validationString ()
 Returns a string representation of this validation object.
 

Additional Inherited Members

- Public Types inherited from creativity::cmdargs::Validation< T >
using value_type = T
 The type T that this object validates.
 
- Protected Attributes inherited from creativity::cmdargs::Validation< T >
val_
 The stored value.
 

Detailed Description

template<typename T, long upper, long denom = 1>
class creativity::cmdargs::Below< T, upper, denom >

Validation wrapper for options that have a strict inequality boundary that the value must be below, such as \(v < 3\).

Parameters
Tany numeric type
upperthe upper bound that the value must be above (or the numerator of the value)
thedenominator under lower. Defaults to 1.
Inheritance diagram for creativity::cmdargs::Below< T, upper, denom >:
[legend]
Collaboration diagram for creativity::cmdargs::Below< T, upper, denom >:
[legend]

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