Functions
checks.h File Reference

Sanity-check functions etc. More...

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void throwIfNotPresent (const bool is_present, const std::string val_desc)
 Throws an exception if the given value is not present. More...
 
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. More...
 

Detailed Description

Sanity-check functions etc.

Definition in file checks.h.

Function Documentation

◆ throwIfNotPresent()

void throwIfNotPresent ( const bool  is_present,
const std::string  val_desc 
)
inline

Throws an exception if the given value is not present.

Parameters
is_presentWhether the value is present.
val_descDescription of the value for the exception message.

Definition at line 57 of file checks.h.

◆ throwIfOutOfRange()

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.

Template Parameters
T1
T2
Parameters
valThe value to check if it is in the range.
minThe minimum value of the range.
maxThe maximum value of the range.
val_descDescription of the value for the exception message.

Definition at line 46 of file checks.h.



etsi_its_msgs_utils
Author(s): Jean-Pierre Busch , Guido Küppers , Lennart Reiher
autogenerated on Sun May 18 2025 02:32:12