![]() |
Diana Software
|
error class with error type and description More...
Public Member Functions | |
| virtual const char * | what () const throw () |
| returns the same information as operator<< More... | |
| QError () | |
| Default constructor. More... | |
| QError (QError_ err) | |
| constructor with error type More... | |
| QError (QError_ err, const std::string &descr) | |
| contructor with error type and description More... | |
| QError (QError_ err, const std::string &file, const int line, const std::string &descr) | |
| constructor with error type, filename, line and description More... | |
| QError (const QError &err) | |
| copy constructor More... | |
| virtual | ~QError () throw () |
| destructor More... | |
| const QError & | operator= (const QError_ &e) |
| assignement operator More... | |
| const QError & | operator= (const QError &err) |
| assignement operator More... | |
| void | SetDescription (const std::string &descr) |
| set error description More... | |
| void | SetDescription (const std::string &file, const int line, const std::string &descr) |
| set error description with file and line More... | |
| const std::string & | GetDescription () const |
| get error description More... | |
| QError_ | GetCode () const |
| get error code More... | |
| const std::string & | ToString () const |
| error type to string conversion More... | |
| bool | operator== (const QError_ &e) const |
| comparison with QError_ enum More... | |
| bool | operator== (const QError &e) const |
| comparison with QError based on enum only More... | |
| bool | operator!= (const QError_ &e) const |
| comparison with QError_ enum More... | |
| bool | operator!= (const QError &e) const |
| comparison with QError based on enum only More... | |
| void | Set (QError_ e=QERR_SUCCESS, const std::string &descr="") |
| set to error code and description (default is SUCCESS) More... | |
| void | Set (QError_ e, const std::string &file, const int line, const std::string &descr="") |
Static Private Member Functions | |
| static void | Init () |
| initialization of fMap More... | |
Private Attributes | |
| QError_ | fErr |
| underlying enum More... | |
| std::string | fDescr |
| error description More... | |
Static Private Attributes | |
| static std::map< QError_, std::string > | fMap |
| map of string error More... | |
Friends | |
| std::ostream & | operator<< (std::ostream &s, const QError &err) |
| stream of error type and description More... | |
error class with error type and description
QFramework errors definition.
Every algorithm or procedure have to use this class for error return, modules will read these errors and decide what to do
| QError::QError | ( | ) |
| QError::QError | ( | QError_ | err | ) |
| QError::QError | ( | QError_ | err, |
| const std::string & | descr | ||
| ) |
| QError::QError | ( | QError_ | err, |
| const std::string & | file, | ||
| const int | line, | ||
| const std::string & | descr | ||
| ) |
| QError::QError | ( | const QError & | err | ) |
|
inlinevirtual | |||||||||||||
|
inline |
| const std::string & QError::GetDescription | ( | ) | const |
get error description
Definition at line 190 of file QError.cc.
References fDescr.
Referenced by GlobalHandle< Q >::Get(), and QSequence::SaveConfig().
|
staticprivate |
initialization of fMap
Definition at line 14 of file QError.cc.
References fMap, QERR_CANNOT_OPEN_FILE, QERR_DB_CONN_FAILED, QERR_DB_INCONSISTENCY, QERR_DB_MAXLINES_EXCEEDED, QERR_DB_NULL_RESULT, QERR_DB_QUERY_FAILED, QERR_ELE_BACKPLANE_READ, QERR_ELE_BACKPLANE_WRITE, QERR_ELE_BESSEL_READ, QERR_ELE_BESSEL_WRITE, QERR_ELE_FE_READ, QERR_ELE_FE_WRITE, QERR_ELE_GENERIC_ERR, QERR_ELE_NO_ACKNOLDGEMENT, QERR_ELE_PULSER_ATT_READ, QERR_ELE_PULSER_ATT_WRITE, QERR_ELE_PULSER_STATUS_READ, QERR_ELE_PULSER_STATUS_WRITE, QERR_ELE_UNDEFINED_REGISTER, QERR_EOF, QERR_EVENT_GENERIC, QERR_EVENT_HANDLE, QERR_EXIT, QERR_FILE_NOT_FOUND, QERR_GLOBAL_GENERIC, QERR_GLOBAL_HANDLE, QERR_GPIB_GENERAL, QERR_GSL_ERROR, QERR_IO_FAILED, QERR_NET_CONNECTION_FAILED, QERR_NET_PROTOCOL, QERR_NET_UNKNOWN_HOST, QERR_NI, QERR_NOT_IMPLEMENTED, QERR_OUT_OF_RANGE, QERR_OVERFLOW, QERR_SHMEM_INVALID_ID, QERR_SHMEM_INVALID_INDEX, QERR_SIZE_NOT_MATCH, QERR_SUCCESS, QERR_TIMEOUT, QERR_TYPE_CONVERSION, QERR_UNDEFINED_BASKET, QERR_UNDEFINED_BOARD, QERR_UNDEFINED_CHANNEL, QERR_UNDEFINED_COMMAND, QERR_UNDEFINED_CRATE, QERR_UNDEFINED_DEVICE, QERR_UNDEFINED_ID, QERR_UNDEFINED_INTERFACE, QERR_UNDEFINED_MODE, QERR_UNDEFINED_NUMBER, QERR_UNDEFINED_PARAMETER, QERR_UNDEFINED_STATUS, QERR_UNDEFINED_TARGET, QERR_UNDEFINED_TYPE, QERR_UNDERFLOW, QERR_UNKNOWN_ERR, QERR_VME_OPEN, QERR_VME_READ, and QERR_VME_WRITE.
Referenced by QError().
|
inline |
|
inline |
|
inline |
|
inline |
| void QError::Set | ( | QError_ | e, |
| const std::string & | file, | ||
| const int | line, | ||
| const std::string & | descr = "" |
||
| ) |
Definition at line 163 of file QError.cc.
References err, fErr, and SetDescription().
| void QError::Set | ( | QError_ | e = QERR_SUCCESS, |
| const std::string & | descr = "" |
||
| ) |
|
inline |
set error description
Definition at line 147 of file QError.hh.
References fDescr.
Referenced by QOptimumFilter::BuildFilter(), GlobalHandle< Q >::FillFromDB(), QRunDataHandle::FillFromDB(), QGSL::InitErrorHandler(), QFileReader::JumpToEvent(), QReader::JumpToEvent(), QError(), QOptimumFilter::QOptimumFilter(), Set(), GlobalHandle< Q >::StoreOnDB(), and GlobalHandle< Q >::StoreOnFile().
| void QError::SetDescription | ( | const std::string & | file, |
| const int | line, | ||
| const std::string & | descr | ||
| ) |
| const std::string & QError::ToString | ( | ) | const |
|
virtual | |||||||||||||
|
friend |
|
private |
error description
Definition at line 187 of file QError.hh.
Referenced by GetDescription(), operator=(), QError(), Set(), and SetDescription().
|
private |
underlying enum
Definition at line 184 of file QError.hh.
Referenced by GetCode(), operator!=(), operator=(), operator==(), QError(), Set(), and ToString().
|
staticprivate |