2013-10-24 17:08:58 +02:00
|
|
|
#ifndef CONCORDIA_EXCEPTION_HDR
|
|
|
|
#define CONCORDIA_EXCEPTION_HDR
|
|
|
|
|
|
|
|
#include<exception>
|
|
|
|
#include<string>
|
|
|
|
#include<string.h>
|
|
|
|
|
|
|
|
/*!
|
|
|
|
Class representing an internal exception thrown in the Concordia library.
|
|
|
|
*/
|
2015-04-15 14:14:10 +02:00
|
|
|
class ConcordiaException : public std::exception {
|
2013-10-24 17:08:58 +02:00
|
|
|
public:
|
|
|
|
/*! Constructor.
|
|
|
|
*/
|
|
|
|
ConcordiaException() throw();
|
|
|
|
|
|
|
|
/*! Constructor with a message.
|
|
|
|
\param message message of the exception
|
|
|
|
*/
|
2015-04-15 14:14:10 +02:00
|
|
|
explicit ConcordiaException(const std::string & message) throw();
|
2013-10-24 17:08:58 +02:00
|
|
|
|
|
|
|
/*! Destructor.
|
|
|
|
*/
|
|
|
|
~ConcordiaException() throw();
|
|
|
|
|
|
|
|
/*! Implementation of the virtual method which provides the exception message.
|
|
|
|
*/
|
|
|
|
virtual const char* what() const throw();
|
|
|
|
|
|
|
|
private:
|
2015-04-15 14:14:10 +02:00
|
|
|
std::string _message;
|
2013-10-24 17:08:58 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|