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