SimGrid  3.21
Versatile Simulation of Distributed Systems

Detailed Description

A legacy exception.

It is defined by a category and a value within that category (as well as an optional error message).

This used to be a structure for C exceptions but it has been retrofitted as a C++ exception and some of its data has been moved in the WithContextException base class. We should deprecate it and replace it with either C++ different exceptions or std::system_error which already provides this (category + error code) logic.

#include <Exception.hpp>

Inherits simgrid::Exception.

Inherited by simgrid::CancelException, simgrid::HostFailureException, simgrid::NetworkFailureException, and simgrid::TimeoutError.

Public Member Functions

 xbt_ex (simgrid::xbt::ThrowPoint throwpoint, std::string message)
 
 ~xbt_ex ()
 
- Public Member Functions inherited from simgrid::Exception
 Exception (simgrid::xbt::ThrowPoint throwpoint, std::string message)
 
xbt::ThrowPoint const & throw_point () const
 Return the information about where the exception was thrown. More...
 

Public Attributes

xbt_errcat_t category = unknown_error
 Category (what went wrong) More...
 
int value = 0
 Why did it went wrong. More...
 

Constructor & Destructor Documentation

◆ xbt_ex()

xbt_ex::xbt_ex ( simgrid::xbt::ThrowPoint  throwpoint,
std::string  message 
)
inline
Parameters
throwpointThrow point (use XBT_THROW_POINT)
messageException message

◆ ~xbt_ex()

xbt_ex::~xbt_ex ( )

Member Data Documentation

◆ category

xbt_errcat_t xbt_ex::category = unknown_error

Category (what went wrong)

◆ value

int xbt_ex::value = 0

Why did it went wrong.


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