StdAir Logo  0.45.1
C++ Standard Airline IT Object Library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AirlineClassList.hpp
Go to the documentation of this file.
1 #ifndef __STDAIR_BOM_AIRLINECLASSLIST_HPP
2 #define __STDAIR_BOM_AIRLINECLASSLIST_HPP
3 
4 // //////////////////////////////////////////////////////////////////////
5 // Import section
6 // //////////////////////////////////////////////////////////////////////
7 // STL
8 #include <iosfwd>
9 #include <string>
10 // StdAir
14 
16 namespace boost {
17  namespace serialization {
18  class access;
19  }
20 }
21 
22 namespace stdair {
23 
27  class AirlineClassList : public BomAbstract {
28  template <typename BOM> friend class FacBom;
29  friend class FacBomManager;
31 
32  public:
33  // ////////// Type definitions ////////////
38 
39 
40  public:
41  // ////////// Getters ////////////
43  const Key_T& getKey() const {
44  return _key;
45  }
46 
48  BomAbstract* const getParent() const {
49  return _parent;
50  }
51 
54  return _key.getAirlineCodeList();
55  }
56 
59  return _key.getClassCodeList();
60  }
61 
63  const HolderMap_T& getHolderMap() const {
64  return _holderMap;
65  }
66 
68  const stdair::Yield_T& getYield() const {
69  return _yield;
70  }
71 
73  const stdair::Fare_T& getFare() const {
74  return _fare;
75  }
76 
77  public:
78  // /////////// Setters //////////////
79  void setYield (const Yield_T& iYield) {
80  _yield = iYield;
81  }
82 
83  void setFare (const Fare_T& iFare) {
84  _fare = iFare;
85  }
86 
87  public:
88  // /////////// Display support methods /////////
94  void toStream (std::ostream& ioOut) const {
95  ioOut << toString();
96  }
97 
103  void fromStream (std::istream& ioIn) {
104  }
105 
109  std::string toString() const;
110 
114  const std::string describeKey() const {
115  return _key.toString();
116  }
117 
118 
119  public:
120  // /////////// (Boost) Serialisation support methods /////////
124  template<class Archive>
125  void serialize (Archive& ar, const unsigned int iFileVersion);
126 
127  private:
132  void serialisationImplementationExport() const;
133  void serialisationImplementationImport();
134 
135 
136  protected:
137  // ////////// Constructors and destructors /////////
141  AirlineClassList (const Key_T&);
145  virtual ~AirlineClassList();
146 
147  private:
152 
157 
158 
159  protected:
160  // ////////// Attributes /////////
165 
170 
175 
176  /*
177  * Yield value.
178  */
180 
181  /*
182  * Fare value.
183  */
185  };
186 
187 }
188 #endif // __STDAIR_BOM_AIRLINECLASSLIST_HPP
189