/* */ #ifndef _D_FATAL_EXCEPTION_H_ #define _D_FATAL_EXCEPTION_H_ #include "Exception.h" namespace aria2 { class FatalException:public Exception { protected: virtual SharedHandle copy() const { SharedHandle e(new FatalException(*this)); return e; } public: FatalException(const char* file, int line, const std::string& msg): Exception(file, line, msg) {} FatalException(const char* file, int line, const std::string& msg, const Exception& cause): Exception(file, line, msg, cause) {} FatalException(const FatalException& e):Exception(e) {} }; #define FATAL_EXCEPTION(arg)\ FatalException(__FILE__, __LINE__, arg) #define FATAL_EXCEPTION2(arg1, arg2)\ FatalException(__FILE__, __LINE__, arg1, arg2) } // namespace aria2 #endif // _D_FATAL_EXCEPTION_EX_H_