svMultiPhysics
Loading...
Searching...
No Matches
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
svmp::ExceptionBase Class Reference
Inheritance diagram for svmp::ExceptionBase:
[legend]

Public Member Functions

const char * what () const noexcept override
 
StatusCode status_code () const noexcept
 
const std::string & message () const noexcept
 
const ExceptionContext & context () const noexcept
 
void add_context (const std::string &context)
 
void set_source_location (const SourceLocation &location)
 Record the originating source location and refresh what().
 

Protected Member Functions

 ExceptionBase (std::string message, StatusCode status, std::string_view subsystem_label, const char *file="", int line=0, const char *function="")
 
void rebuild_what ()
 

Protected Attributes

std::string message_
 
ExceptionContext context_
 
std::string_view subsystem_label_
 
std::string what_
 

Member Function Documentation

◆ set_source_location()

void svmp::ExceptionBase::set_source_location ( const SourceLocation &  location)
inline

Record the originating source location and refresh what().

Called by raise() after construction, so exception constructors do not need to accept (and forward) the file/line/function themselves.


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