TRIQS/nda 1.3.0
Multi-dimensional array library for C++
Loading...
Searching...
No Matches

#include <nda/exceptions.hpp>

Detailed Description

Runtime error class used throughout the nda library.

It inherits from std::exception and overloads the operator<< for easy error message accumulation.

Definition at line 48 of file exceptions.hpp.

Public Member Functions

 runtime_error () noexcept
 Default constructor.
 
 runtime_error (runtime_error const &err) noexcept
 Copy constructor to copy the contents of the error message accumulator.
 
 ~runtime_error () noexcept override=default
 Default destructor.
 
runtime_erroroperator<< (const char *mess)
 Accumulate error message.
 
template<typename T >
runtime_erroroperator<< (T const &x)
 Accumulate error message.
 
const char * what () const noexcept override
 Override the virtual function what from std::exception to retrieve the accumulated error message.
 

Constructor & Destructor Documentation

◆ runtime_error()

nda::runtime_error::runtime_error ( runtime_error const & err)
inlinenoexcept

Copy constructor to copy the contents of the error message accumulator.

Parameters
errRuntime error to copy.

Definition at line 63 of file exceptions.hpp.

Member Function Documentation

◆ operator<<() [1/2]

runtime_error & nda::runtime_error::operator<< ( const char * mess)
inline

Accumulate error message.

Parameters
messMessage to accumulate.
Returns
Reference to this with the input message appended to the error message.

Definition at line 87 of file exceptions.hpp.

◆ operator<<() [2/2]

template<typename T >
runtime_error & nda::runtime_error::operator<< ( T const & x)
inline

Accumulate error message.

Template Parameters
TType to accumulate.
Parameters
xInput value to accumulate.
Returns
Reference to this with the input value appended to the error message.

Definition at line 76 of file exceptions.hpp.

◆ what()

const char * nda::runtime_error::what ( ) const
inlineoverridenoexcept

Override the virtual function what from std::exception to retrieve the accumulated error message.

Returns
Error message.

Definition at line 96 of file exceptions.hpp.


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