50 explicit Exception(
const std::string & what ) ;
53 Exception(
const char * what ,
const std::string & more ) ;
56 Exception(
const std::string & what ,
const std::string & more ) ;
59 Exception(
const char * what ,
const std::string & more1 ,
const std::string & more2 ) ;
62 Exception(
const std::string & what ,
const std::string & more1 ,
const std::string & more2 ) ;
65 Exception(
const char * what ,
const std::string & more1 ,
const std::string & more2 ,
const std::string & more3 ) ;
68 Exception(
const std::string & what ,
const std::string & more1 ,
const std::string & more2 ,
const std::string & more3 ) ;
72#define G_EXCEPTION_CLASS( class_name , description ) class class_name : public G::Exception { public: class_name() : G::Exception((description)) {} explicit class_name(const char *more) : G::Exception((description),more) {} explicit class_name(const std::string &more) : G::Exception((description),more) {} class_name(const std::string &more1,const std::string &more2) : G::Exception((description),more1,more2) {} class_name(const std::string &more1,const std::string &more2,const std::string &more3) : G::Exception((description),more1,more2,more3) {} }
74#define G_EXCEPTION_FUNCTION( name , description ) \
75 inline static G::Exception name() { return G::Exception((description)) ; } \
76 inline static G::Exception name( const std::string & s ) { return G::Exception((description),s) ; } \
77 inline static G::Exception name( const std::string & s1 , const std::string & s2 ) { return G::Exception((description),s1,s2) ; } \
78 inline static G::Exception name( const std::string & s1 , const std::string & s2 , const std::string & s3 ) { return G::Exception((description),s1,s2,s3) ; }
86#define G_EXCEPTION( class_name , description ) G_EXCEPTION_FUNCTION( class_name , description )
A general-purpose exception class derived from std::exception and containing an error message.
Exception(const char *what)
Constructor.