RMOL Logo  1.00.0
C++ library of Revenue Management and Optimisation classes and functions
 All Classes Namespaces Files Functions Variables Typedefs Friends Pages
RMOL_Types.hpp
Go to the documentation of this file.
1 #ifndef __RMOL_RMOL_TYPES_HPP
2 #define __RMOL_RMOL_TYPES_HPP
3 
4 // //////////////////////////////////////////////////////////////////////
5 // Import section
6 // //////////////////////////////////////////////////////////////////////
7 // STL
8 #include <map>
9 #include <vector>
10 // Boost
11 #include <boost/shared_ptr.hpp>
12 // StdAir
13 #include <stdair/stdair_inventory_types.hpp>
14 #include <stdair/stdair_rm_types.hpp>
15 #include <stdair/stdair_exceptions.hpp>
16 
17 // Forward declarations.
18 namespace stdair {
19  class BookingClass;
20 }
21 
22 
23 namespace RMOL {
24 
25  // Forward declarations
26  class RMOL_Service;
27 
28  // ///////// Exceptions ///////////
32  class OverbookingException : public stdair::RootException {
33  public:
35  OverbookingException (const std::string& iWhat)
36  : stdair::RootException (iWhat) {}
37  };
38 
42  class UnconstrainingException : public stdair::RootException {
43  public:
45  UnconstrainingException (const std::string& iWhat)
46  : stdair::RootException (iWhat) {}
47  };
48 
53  public:
55  EmptyNestingStructException (const std::string& iWhat)
56  : UnconstrainingException (iWhat) {}
57  };
58 
63  public:
65  MissingDCPException (const std::string& iWhat)
66  : UnconstrainingException (iWhat) {}
67  };
68 
72  class OptimisationException : public stdair::RootException {
73  public:
75  OptimisationException (const std::string& iWhat)
76  : stdair::RootException (iWhat) {}
77  };
78 
82  class PolicyException : public stdair::RootException {
83  public:
85  PolicyException (const std::string& iWhat)
86  : stdair::RootException (iWhat) {}
87  };
88 
89 
94  public:
96  ConvexHullException (const std::string& iWhat)
97  : PolicyException (iWhat) {}
98  };
99 
104  public:
106  EmptyConvexHullException (const std::string& iWhat)
107  : ConvexHullException (iWhat) {}
108  };
109 
114  public:
116  FirstPolicyNotNullException (const std::string& iWhat)
117  : ConvexHullException (iWhat) {}
118  };
119 
124  public:
126  YieldConvexHullException (const std::string& iWhat)
127  : ConvexHullException (iWhat) {}
128  };
129 
130 
134  class FareFamilyException : public stdair::RootException {
135  public:
137  FareFamilyException (const std::string& iWhat)
138  : stdair::RootException (iWhat) {}
139  };
140 
145  public:
147  EmptyBookingClassListException (const std::string& iWhat)
148  : FareFamilyException (iWhat) {}
149  };
150 
155  public:
157  MissingBookingClassInFareFamilyException (const std::string& iWhat)
158  : FareFamilyException (iWhat) {}
159  };
160 
165  public:
167  FareFamilyDemandVectorSizeException (const std::string& iWhat)
168  : FareFamilyException (iWhat) {}
169  };
170 
171 
172  // //////// Type definitions /////////
176  typedef boost::shared_ptr<RMOL_Service> RMOL_ServicePtr_T;
177 
179  typedef std::vector<stdair::Flag_T> FlagVector_T;
180 
182  typedef std::map<stdair::BookingClass*, stdair::MeanStdDevPair_T> BookingClassMeanStdDevPairMap_T;
183 }
184 #endif // __RMOL_RMOL_TYPES_HPP