mirror of
https://github.com/ONLYOFFICE/core.git
synced 2026-07-13 16:24:45 +08:00
33 lines
613 B
C++
33 lines
613 B
C++
#pragma once
|
|
|
|
#include <exception>
|
|
#include <string>
|
|
|
|
namespace CFCPP
|
|
{
|
|
class CFException : virtual public std::exception
|
|
{
|
|
public:
|
|
CFException() {}
|
|
CFException(std::string message) : errorMessage(message) {}
|
|
virtual ~CFException() throw () {}
|
|
|
|
virtual const char* what() const throw () {
|
|
return errorMessage.c_str();
|
|
}
|
|
|
|
protected:
|
|
std::string errorMessage;
|
|
};
|
|
|
|
class CFFileFormatException : public CFException
|
|
{
|
|
public:
|
|
CFFileFormatException() {}
|
|
CFFileFormatException(std::string message) : CFException(message) {}
|
|
virtual ~CFFileFormatException() throw () {}
|
|
};
|
|
|
|
|
|
}
|