Rivet  1.8.3
Exceptions.hh
1 #ifndef RIVET_EXCEPTIONS_HH
2 #define RIVET_EXCEPTIONS_HH
3 
4 #include <string>
5 #include <exception>
6 #include <stdexcept>
7 
8 namespace Rivet {
9 
10 
12  class Error : public std::runtime_error {
13  public:
14  Error(const std::string& what) : std::runtime_error(what) {}
15  };
16 
17 
19  typedef Error Exception;
20 
21 
23  class RangeError : public Error {
24  public:
25  RangeError(const std::string& what) : Error(what) {}
26  };
27 
28 
30  class LogicError : public Error {
31  public:
32  LogicError(const std::string& what) : Error(what) {}
33  };
34 
35 
37  class PidError : public Error {
38  public:
39  PidError(const std::string& what) : Error(what) {}
40  };
41 
42 
47  class WeightError : public Error {
48  public:
49  WeightError(const std::string& what) : Error(what) {}
50  };
51 
52 
54  class UserError : public Error {
55  public:
56  UserError(const std::string& what) : Error(what) {}
57  };
58 
59 
60 }
61 
62 #endif