aGrUM 2.3.2
a C++ library for (probabilistic) graphical models
gum::Exception Class Reference

Base class for all aGrUM's exceptions. More...

#include <exceptions.h>

Inheritance diagram for gum::Exception:

Public Member Functions

GUM_NODISCARD const char * what () const noexcept override
GUM_NODISCARD std::string errorContent () const
 Returns the message content.
GUM_NODISCARD std::string errorType () const
 Returns the error type.
GUM_NODISCARD std::string errorCallStack () const
 Returns the error call stack.
Class constructors & destructors
 Exception (std::string aMsg="", std::string aType="Generic error")
 Exception (const Exception &e)
virtual ~Exception ()=default

Protected Attributes

std::string msg_
std::string type_
std::string callstack_
std::string what_

Detailed Description

Base class for all aGrUM's exceptions.

Definition at line 118 of file exceptions.h.

Constructor & Destructor Documentation

◆ Exception() [1/2]

gum::Exception::Exception ( std::string aMsg = "",
std::string aType = "Generic error" )
explicit

Referenced by Exception().

Here is the caller graph for this function:

◆ Exception() [2/2]

gum::Exception::Exception ( const Exception & e)

References Exception().

Here is the call graph for this function:

◆ ~Exception()

virtual gum::Exception::~Exception ( )
virtualdefault

Member Function Documentation

◆ errorCallStack()

GUM_NODISCARD std::string gum::Exception::errorCallStack ( ) const
inline

Returns the error call stack.

Returns
Returns the error call stack.

Definition at line 156 of file exceptions.h.

156{ return callstack_; };
std::string callstack_
Definition exceptions.h:122

References callstack_, and GUM_NODISCARD.

◆ errorContent()

GUM_NODISCARD std::string gum::Exception::errorContent ( ) const
inline

Returns the message content.

Returns
Returns the message content.

Definition at line 144 of file exceptions.h.

144{ return msg_; };
std::string msg_
Definition exceptions.h:120

References GUM_NODISCARD, and msg_.

Referenced by gum::MultiDimBucket< GUM_SCALAR >::_computeValue_(), gum::prm::o3prmr::O3prmrInterpreter::checkObserve(), gum::prm::o3prmr::O3prmrInterpreter::checkQuery(), gum::prm::o3prmr::O3prmrInterpreter::checkSemantic(), gum::prm::o3prmr::O3prmrInterpreter::checkUnobserve(), gum::prm::o3prmr::O3prmrInterpreter::import(), gum::prm::o3prmr::O3prmrInterpreter::interpret(), and gum::prm::o3prm::O3prmReader< GUM_SCALAR >::readFile().

Here is the caller graph for this function:

◆ errorType()

GUM_NODISCARD std::string gum::Exception::errorType ( ) const
inline

Returns the error type.

Returns
Returns the error type.

Definition at line 150 of file exceptions.h.

150{ return type_; };
std::string type_
Definition exceptions.h:121

References GUM_NODISCARD, and type_.

◆ what()

GUM_NODISCARD const char * gum::Exception::what ( ) const
inlineoverridenoexcept

Definition at line 138 of file exceptions.h.

138{ return what_.c_str(); };
std::string what_
Definition exceptions.h:123

References GUM_NODISCARD, and what_.

Member Data Documentation

◆ callstack_

std::string gum::Exception::callstack_
protected

Definition at line 122 of file exceptions.h.

Referenced by errorCallStack().

◆ msg_

std::string gum::Exception::msg_
protected

Definition at line 120 of file exceptions.h.

Referenced by errorContent().

◆ type_

std::string gum::Exception::type_
protected

Definition at line 121 of file exceptions.h.

Referenced by errorType().

◆ what_

std::string gum::Exception::what_
protected

Definition at line 123 of file exceptions.h.

Referenced by what().


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