Sanity-check functions etc. More...
Go to the source code of this file.
Functions | |
| template<typename T1, typename T2> | |
| void | throwIfOutOfRange (const T1 &val, const T2 &min, const T2 &max, const std::string val_desc) |
| Throws an exception if a given value is out of a defined range. | |
| void | throwIfNotPresent (const bool is_present, const std::string val_desc) |
| Throws an exception if the given value is not present. | |
Sanity-check functions etc.
Definition in file checks.h.
|
inline |
| void throwIfOutOfRange | ( | const T1 & | val, |
| const T2 & | min, | ||
| const T2 & | max, | ||
| const std::string | val_desc ) |
Throws an exception if a given value is out of a defined range.
| T1 | |
| T2 |
| val | The value to check if it is in the range. |
| min | The minimum value of the range. |
| max | The maximum value of the range. |
| val_desc | Description of the value for the exception message. |
Definition at line 46 of file checks.h.