public: \
ClassName() throw() {Init();} \
ClassName(const ClassName & rh) throw() : \
BUException::exBase(rh) {Init();Copy(rh);} \
ClassName & operator=(const ClassName & rh) throw() \
{Init();Copy(rh);return *this;} \
~ClassName() throw() {} \
const char * what() const throw() {return whatname;} \
private: \
void Init() \
{ \
strcpy(whatname,ClassDescription); \
} \
char whatname[sizeof(ClassDescription)]; \
};
28#define ExceptionClassGenerator( ClassName , ClassDescription ) \
29 class ClassName : public BUException::exBase { \
30 public: \
31 ClassName() throw() {Init();} \
32 ClassName(const ClassName & rh) throw() : \
33 BUException::exBase(rh) {Init();Copy(rh);} \
34 ClassName & operator=(const ClassName & rh) throw() \
35 {Init();Copy(rh);return *this;} \
36 ~ClassName() throw() {} \
37 const char * what() const throw() {return whatname;} \
38 private: \
39 void Init() \
40 { \
41 strcpy(whatname,ClassDescription); \
42 } \
43 char whatname[sizeof(ClassDescription)]; \
44 };