Moved TranslatorException class to utils directory.

This commit is contained in:
2016-06-10 17:21:56 +02:00
parent f6cfc55e21
commit 6a83147ac0
2 changed files with 4 additions and 6 deletions

View File

@@ -1,56 +0,0 @@
#ifndef __PLASP__SAS__TRANSLATOR_EXCEPTION_H
#define __PLASP__SAS__TRANSLATOR_EXCEPTION_H
#include <exception>
#include <string>
namespace plasp
{
namespace sas
{
////////////////////////////////////////////////////////////////////////////////////////////////////
//
// TranslatorException
//
////////////////////////////////////////////////////////////////////////////////////////////////////
class TranslatorException: public std::exception
{
public:
explicit TranslatorException()
{
}
explicit TranslatorException(const char *message)
: m_message(message)
{
}
explicit TranslatorException(const std::string &message)
: m_message(message)
{
}
~TranslatorException() throw()
{
}
const char *what() const throw()
{
if (m_message.empty())
return "Unspecified error while translating SAS description";
return m_message.c_str();
}
private:
std::string m_message;
};
////////////////////////////////////////////////////////////////////////////////////////////////////
}
}
#endif