PandaRoot
GFException Class Reference

Exception class for error handling in GENFIT (provides storage for diagnostic information) More...

#include <GFException.h>

Inheritance diagram for GFException:

Public Member Functions

 GFException (std::string, int, std::string)
 Initializing constructor. More...
 
virtual ~GFException () throw ()
 
void setFatal (bool b=true)
 set fatal flag. if this is true, the fit stops for this current track repr. 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< TMatrixT< double >> &)
 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)
 

Detailed Description

Exception class for error handling in GENFIT (provides storage for diagnostic information)

Author
Christian Höppner (Technische Universität München, original author)
Sebastian Neubert (Technische Universität München, original author)

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 44 of file GFException.h.

Constructor & Destructor Documentation

◆ GFException()

GFException::GFException ( std::string  ,
int  ,
std::string   
)

Initializing constructor.

Parameters
whaterror message
lineline at which the exception is created. Can be set through LINE macro
filesorcefile in which the exception is created. Can be set through FILE macro

◆ ~GFException()

virtual GFException::~GFException ( )
throw (
)
virtual

Member Function Documentation

◆ getExcString()

std::string GFException::getExcString ( )
inline

Definition at line 88 of file GFException.h.

88 { return fExcString; }

◆ info()

void GFException::info ( )

print information in the exception object

Referenced by isFatal().

◆ isFatal()

bool GFException::isFatal ( )
inline

get fatal flag.

Definition at line 76 of file GFException.h.

References info(), setMatrices(), setNumbers(), and what().

76 { return fFatal; }

◆ quiet()

static void GFException::quiet ( bool  b = true)
inlinestatic

Definition at line 90 of file GFException.h.

90 { fQuiet = b; }

◆ setFatal()

void GFException::setFatal ( bool  b = true)
inline

set fatal flag. if this is true, the fit stops for this current track repr.

Definition at line 74 of file GFException.h.

Referenced by PndFtsRecoHitProducer< hit_T, recoHit_T >::produce(), PndSttRecoHitProducer< hit_T, recoHit_T >::produce(), and GFRecoHitProducer< hit_T, recoHit_T >::produce().

74 { fFatal = b; }

◆ setMatrices()

void GFException::setMatrices ( std::string  ,
const std::vector< TMatrixT< double >> &   
)

set list of matrices with description

Referenced by isFatal().

◆ setNumbers()

void GFException::setNumbers ( std::string  ,
const std::vector< double > &   
)

set list of numbers with description

Referenced by isFatal().

◆ what()

virtual const char* GFException::what ( ) const
throw (
)
virtual

standard error message handling for exceptions. use like "std::cerr << e.what();"

Referenced by isFatal().


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