dynamic-graph  4.4.3
Dynamic graph library
ExceptionAbstract Class Reference

Abstract root class for all dynamic-graph exceptions. More...

#include <dynamic-graph/exception-abstract.h>

Inheritance diagram for ExceptionAbstract:
Collaboration diagram for ExceptionAbstract:

Classes

class  Param
 Class owned by exceptions to store error locations. More...
 

Public Types

enum  ExceptionEnum {
  ABSTRACT = 0, SIGNAL = 100, FACTORY = 200, TRACES = 300,
  TOOLS = 700
}
 Categories error code. More...
 

Public Member Functions

 ExceptionAbstract (const int &code, const std::string &msg="")
 
int getCode () const
 Access to the error code.
 
virtual const std::string & getExceptionName () const
 
const char * getMessage () const
 Access to the pointer on the array of char related to the error string. More...
 
const std::string & getStringMessage () const
 Reference access to the error message (can be empty).
 
virtual const char * what () const throw ()
 

Static Public Attributes

static const std::string EXCEPTION_NAME
 

Protected Attributes

int code
 Error code. More...
 
std::string message
 Error message (can be empty).
 

Friends

DYNAMIC_GRAPH_DLLAPI friend std::ostream & operator<< (std::ostream &os, const ExceptionAbstract &err)
 Print the error structure.
 

Detailed Description

Abstract root class for all dynamic-graph exceptions.

Definition at line 31 of file exception-abstract.h.

Member Enumeration Documentation

◆ ExceptionEnum

Categories error code.

Each value matches categories used by a subclass of ExceptionAbstract.

This is the programmer responsibility to make sure there is enough room between two categories error code.

Definition at line 67 of file exception-abstract.h.

Member Function Documentation

◆ getMessage()

const char* getMessage ( ) const

Access to the pointer on the array of char related to the error string.

Cannot be NULL.

Member Data Documentation

◆ code

int code
protected

Error code.

See also
ErrorCodeEnum

Definition at line 105 of file exception-abstract.h.


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