FairRoot/PandaRoot
|
Exception class for error handling in GENFIT (provides storage for diagnostic information) More...
#include <Exception.h>
Public Member Functions | |
Exception (std::string excString, int line, std::string file) | |
Initializing constructor. More... | |
virtual | ~Exception () throw () |
void | setFatal (bool b=true) |
Set fatal flag. More... | |
bool | isFatal () |
Get fatal flag. More... | |
void | setNumbers (std::string, const std::vector< double > &) |
Set list of numbers with description. More... | |
void | setMatrices (std::string, const std::vector< TMatrixD > &) |
Set list of matrices with description. More... | |
void | info () |
Print information in the exception object. More... | |
virtual const char * | what () const throw () |
Standard error message handling for exceptions. use like "std::cerr << e.what();". More... | |
std::string | getExcString () |
Static Public Member Functions | |
static void | quiet (bool b=true) |
"std::cerr << e.what();" will not write anything. More... | |
Private Attributes | |
std::string | excString_ |
int | line_ |
std::string | file_ |
std::string | errorMessage_ |
std::string | numbersLabel_ |
std::string | matricesLabel_ |
std::vector< double > | numbers_ |
std::vector< TMatrixD > | matrices_ |
bool | fatal_ |
Static Private Attributes | |
static bool | quiet_ |
Exception class for error handling in GENFIT (provides storage for diagnostic information)
This is the class that is used for all error handling in GENFIT. It is a utility class that allows to store numbers and matrices together with an error string. The exception class can then be thrown when an error is detected and the C++ exception handling facilities can be used to catch and process the exception.
Definition at line 48 of file Exception.h.
genfit::Exception::Exception | ( | std::string | excString, |
int | line, | ||
std::string | file | ||
) |
Initializing constructor.
excString | error message. |
line | line at which the exception is created. Can be set through LINE macro. |
file | sourcefile in which the exception is created. Can be set through FILE macro. |
|
virtual |
|
inline |
void genfit::Exception::info | ( | ) |
Print information in the exception object.
|
inline |
|
inlinestatic |
"std::cerr << e.what();" will not write anything.
Definition at line 78 of file Exception.h.
Referenced by PndRecoDafFit2::Init(), and PndRecoKalmanFit2::Init().
|
inline |
Set fatal flag.
Definition at line 61 of file Exception.h.
Referenced by genfit::MeasurementFactory< measurement_T >::addProducer(), genfit::MeasurementFactory< measurement_T >::createOne(), PndSttRecoHitProducer2< hit_T, measurement_T >::produce(), PndFtsRecoHitProducer2< hit_T, measurement_T >::produce(), and genfit::MeasurementProducer< hit_T, measurement_T >::produce().
void genfit::Exception::setMatrices | ( | std::string | , |
const std::vector< TMatrixD > & | |||
) |
Set list of matrices with description.
void genfit::Exception::setNumbers | ( | std::string | , |
const std::vector< double > & | |||
) |
Set list of numbers with description.
Referenced by genfit::MeasurementFactory< measurement_T >::addProducer(), and genfit::MeasurementFactory< measurement_T >::createOne().
|
virtual |
Standard error message handling for exceptions. use like "std::cerr << e.what();".
Referenced by PndRecoDafFit2::Fit(), and PndRecoKalmanFit2::Fit().
|
private |
Definition at line 88 of file Exception.h.
|
private |
Definition at line 84 of file Exception.h.
Referenced by getExcString().
|
private |
Definition at line 95 of file Exception.h.
Referenced by isFatal(), and setFatal().
|
private |
Definition at line 86 of file Exception.h.
|
private |
Definition at line 85 of file Exception.h.
|
private |
Definition at line 93 of file Exception.h.
|
private |
Definition at line 91 of file Exception.h.
|
private |
Definition at line 92 of file Exception.h.
|
private |
Definition at line 90 of file Exception.h.
|
staticprivate |
Definition at line 82 of file Exception.h.
Referenced by quiet().