last update 20 Sep 2009 |
#include <cvrStatusMonitor.h>
Public Member Functions | |
statusMonitor () | |
virtual | ~statusMonitor () |
virtual const std::string & | name () const =0 |
virtual statusMonitor * | clone () const =0 |
virtual statusMonitor * | newInstance () const =0 |
virtual void | set (const std::string &id, const char *msg)=0 |
virtual void | set (const std::string &id, const std::string &msg)=0 |
Status monitors are objects that control what to do when an error is reported: should it just be ignored? should it throw and exception? should it be streamed out to std::cerr?
You can call the global function cvr::setStatusMonitor() to set the object for the whole library.
This is an abstract class.
cvr::statusMonitor::statusMonitor | ( | ) |
Default constructor.
virtual cvr::statusMonitor::~statusMonitor | ( | ) | [virtual] |
Destructor.
virtual statusMonitor* cvr::statusMonitor::clone | ( | ) | const [pure virtual] |
Return a static instance of the current object type, which is not clonable since it has a singleton pattern.
Implements cvr::object.
Implemented in cvr::statusMonitorCerr, and cvr::statusMonitorException.
virtual const std::string& cvr::statusMonitor::name | ( | ) | const [pure virtual] |
Return the name of this class.
Implements cvr::object.
Implemented in cvr::statusMonitorCerr, and cvr::statusMonitorException.
virtual statusMonitor* cvr::statusMonitor::newInstance | ( | ) | const [pure virtual] |
Return a static instance of the current object type.
Implements cvr::object.
Implemented in cvr::statusMonitorCerr, and cvr::statusMonitorException.
virtual void cvr::statusMonitor::set | ( | const std::string & | id, | |
const std::string & | msg | |||
) | [pure virtual] |
Set a status string.
id | of the reporting class. Usually you give here the output of name(). | |
msg | the const string to be reported. |
Implemented in cvr::statusMonitorCerr, and cvr::statusMonitorException.
virtual void cvr::statusMonitor::set | ( | const std::string & | id, | |
const char * | msg | |||
) | [pure virtual] |
Set a status string.
id | of the reporting class. Usually you give here the output of name(). | |
msg | the const string to be reported. |
Implemented in cvr::statusMonitorCerr, and cvr::statusMonitorException.