00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012 #ifndef FITSERROR_H
00013 #define FITSERROR_H 1
00014 #include <exception>
00015 #include <iostream>
00016
00017
00018
00019 #include <string>
00020 using std::string;
00021
00022
00023 namespace CCfits {
00024
00091
00092
00093
00094
00095
00096 class FitsException
00097 {
00098 public:
00099 FitsException (const string& msg, bool& silent);
00100
00101 const string& message () const;
00102
00103 protected:
00104 void addToMessage (const string& msgQual);
00105
00106 private:
00107 private:
00108
00109 string m_message;
00110
00111 };
00112
00113
00114
00115 class FitsError : public FitsException
00116 {
00117 public:
00118 FitsError (int errornum, bool silent = true);
00119
00120 protected:
00121 private:
00122 void printMsg (int error);
00123
00124 private:
00125 };
00126
00127
00128
00129 class FitsFatal
00130 {
00131 public:
00132 FitsFatal (const string& diag);
00133
00134 protected:
00135 private:
00136 private:
00137 };
00138
00139
00140
00141 inline const string& FitsException::message () const
00142 {
00143 return m_message;
00144 }
00145
00146
00147
00148
00149
00150 }
00151
00152
00153 #endif