CMS 3D CMS Logo

MagExceptions.h
Go to the documentation of this file.
1 #ifndef Mag_MagExceptions_H
2 #define Mag_MagExceptions_H
3 
4 #include <exception>
5 #include <string>
6 
7 class MagException : public std::exception {
8 public:
10  MagException(const char *message);
11  ~MagException() throw() override;
12  const char *what() const throw() override;
13 
14 private:
15  std::string theMessage;
16 };
17 
19 public:
21  MagGeometryError(const char *message) : MagException(message) {}
22  ~MagGeometryError() throw() override {}
23 };
24 
25 class MagLogicError : public MagException {
26 public:
28  MagLogicError(const char *message) : MagException(message) {}
29  ~MagLogicError() throw() override {}
30 };
31 
33 public:
34  GridInterpolator3DException(double a1, double b1, double c1, double a2, double b2, double c2) throw();
35  ~GridInterpolator3DException() throw() override;
36  const char *what() const throw() override;
37  double *limits(void) { return limits_; }
38 
39 protected:
40  double limits_[6];
41 };
42 
43 #endif
~MagGeometryError() override
Definition: MagExceptions.h:22
MagLogicError(const char *message)
Definition: MagExceptions.h:28
~MagLogicError() override
Definition: MagExceptions.h:29
const char * what() const override
Definition: MagExceptions.cc:5
MagGeometryError(const char *message)
Definition: MagExceptions.h:21
~MagException() override
Definition: MagExceptions.cc:4
std::string theMessage
Definition: MagExceptions.h:15
static constexpr float b2
static constexpr float b1