00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00030 #ifndef EXPANDLIB_EXCEPTIONS_H_INCLUDED
00031 #define EXPANDLIB_EXCEPTIONS_H_INCLUDED
00032
00033 namespace expander {
00034
00036
00037 class general_error {
00038 private:
00039 const _TCHAR* context_;
00040 const _TCHAR* error_message_;
00041 const _TCHAR* about_;
00042
00043 public:
00044 general_error (const _TCHAR* context, const _TCHAR* error_message) throw() :
00045 context_(context),
00046 error_message_(error_message),
00047 about_("")
00048 {}
00049
00050 general_error (const _TCHAR* context, const _TCHAR* error_message, const _TCHAR* about) throw() :
00051 context_(context),
00052 error_message_(error_message),
00053 about_(about)
00054 {}
00055
00056 inline const _TCHAR* context () const throw()
00057 {
00058 return context_;
00059 }
00060 inline const _TCHAR* error_message () const throw()
00061 {
00062 return error_message_;
00063 }
00064 inline const _TCHAR* about () const throw()
00065 {
00066 return about_;
00067 }
00068 };
00069
00070
00072
00073 class expand_error {
00074 private:
00075 const _TCHAR* context_;
00076 const _TCHAR* error_message_;
00077 const _TCHAR* about_;
00078
00079 public:
00080 expand_error (const _TCHAR* context, const _TCHAR* error_message) throw() :
00081 context_(context),
00082 error_message_(error_message),
00083 about_("")
00084 {}
00085
00086 expand_error (const _TCHAR* context, const _TCHAR* error_message, const _TCHAR* about) throw() :
00087 context_(context),
00088 error_message_(error_message),
00089 about_(about)
00090 {}
00091
00092 inline const _TCHAR* context () const throw()
00093 {
00094 return context_;
00095 }
00096 inline const _TCHAR* error_message () const throw()
00097 {
00098 return error_message_;
00099 }
00100 inline const _TCHAR* about () const throw()
00101 {
00102 return about_;
00103 }
00104 };
00105
00106 }
00107
00108 #endif //EXPANDLIB_EXCEPTIONS_H_INCLUDED