Go to the documentation of this file.
29 #ifndef _GG_Exception_h_
30 #define _GG_Exception_h_
52 virtual const char* type()
const throw() = 0;
53 virtual const
char* what() const throw() {
return m_msg.c_str();}
61 #define GG_EXCEPTION( name ) \
62 class GG_API name : public ExceptionBase \
65 name () throw() : ExceptionBase() {} \
66 name (const std::string& msg) throw() : ExceptionBase(msg) {} \
67 virtual const char* type() const throw() \
68 {return "GG::" # name ;} \
74 #define GG_ABSTRACT_EXCEPTION( name ) \
75 class GG_API name : public ExceptionBase \
78 name () throw() : ExceptionBase() {} \
79 name (const std::string& msg) throw() : ExceptionBase(msg) {} \
80 virtual const char* type() const throw() = 0; \
86 #define GG_CONCRETE_EXCEPTION( name, class_name, superclass ) \
87 class GG_API name : public superclass \
90 name () throw() : superclass () {} \
91 name (const std::string& msg) throw() : superclass (msg) {} \
92 virtual const char* type() const throw() \
93 {return # class_name "::" # name ;} \