RestrictedInt.hh File Reference

RestrictedInt public header. More...

#include <boost/operators.hpp>
#include <senf/Utils/safe_bool.hh>
Include dependency graph for RestrictedInt.hh:

Go to the source code of this file.

Classes

class  senf::RestrictedInt< Base, Tag >
 

Namespaces

 senf
 

Macros

#define BinaryOp(op)
 
#define IncDecOp(op)
 
#define PrefixOp(op)
 
#define CompareOp(op)
 

Functions

template<class Base , class Tag , typename OtherType >
RestrictedInt< Base, Tag > senf::operator* (OtherType a, RestrictedInt< Base, Tag > b)
 
template<class Base , class Tag , typename OtherType >
RestrictedInt< Base, Tag > senf::operator* (RestrictedInt< Base, Tag > a, OtherType b)
 
template<class Base , class Tag , typename OtherType >
RestrictedInt< Base, Tag > senf::operator/ (OtherType a, RestrictedInt< Base, Tag > b)
 
template<class Base , class Tag , typename OtherType >
RestrictedInt< Base, Tag > senf::operator/ (RestrictedInt< Base, Tag > a, OtherType b)
 
template<class Base , class Tag >
std::ostream & senf::operator<< (std::ostream &os, RestrictedInt< Base, Tag > value)
 
template<class Base , class Tag >
std::istream & senf::operator>> (std::istream &is, RestrictedInt< Base, Tag > &value)
 

Detailed Description

RestrictedInt public header.

Definition in file RestrictedInt.hh.

Macro Definition Documentation

◆ BinaryOp

#define BinaryOp (   op)
Value:
RestrictedInt & operator op ## = (RestrictedInt other) \
{ value_ op ## = other.value_; return *this; }

Definition at line 48 of file RestrictedInt.hh.

◆ CompareOp

#define CompareOp (   op)
Value:
bool operator op (RestrictedInt other) const \
{ return value_ op other.value_; }

Definition at line 57 of file RestrictedInt.hh.

◆ IncDecOp

#define IncDecOp (   op)
Value:
RestrictedInt & operator op () \
{ op value_; return *this; }

Definition at line 51 of file RestrictedInt.hh.

◆ PrefixOp

#define PrefixOp (   op)
Value:
RestrictedInt const operator op () const \
{ return RestrictedInt(op value_); }

Definition at line 54 of file RestrictedInt.hh.