StdAir Logo  1.00.3
C++ Standard Airline IT Object Library
YieldFeatures.hpp
Go to the documentation of this file.
1 #ifndef __STDAIR_BOM_YIELDFEATURES_HPP
2 #define __STDAIR_BOM_YIELDFEATURES_HPP
3 
4 // //////////////////////////////////////////////////////////////////////
5 // Import section
6 // //////////////////////////////////////////////////////////////////////
7 // StdAir
11 
12 // Forward declaration
13 namespace stdair {
14 
19  class YieldFeatures : public BomAbstract {
20  template <typename BOM> friend class FacBom;
21  template <typename BOM> friend class FacCloneBom;
22  friend class FacBomManager;
23 
24  public:
25  // /////// Type definitions
30 
31  public:
32  // /////////// Display support methods /////////
38  void toStream (std::ostream& ioOut) const {
39  ioOut << toString();
40  }
41 
47  void fromStream (std::istream& ioIn) {
48  }
49 
53  std::string toString() const;
54 
58  const std::string describeKey() const {
59  return _key.toString();
60  }
61 
62  public:
63  // ////////// Getters ////////////
67  const Key_T& getKey() const {
68  return _key;
69  }
70 
74  BomAbstract* const getParent() const {
75  return _parent;
76  }
77 
81  const HolderMap_T& getHolderMap() const {
82  return _holderMap;
83  }
84 
88  const CabinCode_T& getCabinCode() const {
89  return _key.getCabinCode();
90  }
91 
95  const TripType_T& getTripType() const {
96  return _key.getTripType();
97  }
98 
99 
100  public:
101  // ////////////// Business methods ///////////////
106  bool isTripTypeValid (const TripType_T&) const;
107 
108 
109  protected:
110  // ////////// Constructors and destructors /////////
114  YieldFeatures (const Key_T&);
115 
119  virtual ~YieldFeatures();
120 
121  private:
125  YieldFeatures();
126 
130  YieldFeatures (const YieldFeatures&);
131 
132 
133  protected:
134  // ////////// Attributes /////////
138  Key_T _key;
139 
144 
149  };
150 
151 }
152 #endif // __STDAIR_BOM_YIELDFEATURES_HPP
153 
YieldFeaturesKey Key_T
std::string CabinCode_T
const HolderMap_T & getHolderMap() const
Utility class for linking StdAir-based objects.
std::string TripType_T
const CabinCode_T & getCabinCode() const
Handle on the StdAir library context.
std::map< const std::type_info *, BomAbstract * > HolderMap_T
Definition: BomAbstract.hpp:63
Base class for the Business Object Model (BOM) layer.
Definition: BomAbstract.hpp:24
const std::string toString() const
BomAbstract *const getParent() const
std::string toString() const
Base class for Factory layer.
Definition: FacBom.hpp:22
void toStream(std::ostream &ioOut) const
Key of date-period.
const std::string describeKey() const
const Key_T & getKey() const
const TripType_T & getTripType() const
const CabinCode_T & getCabinCode() const
void fromStream(std::istream &ioIn)
const TripType_T & getTripType() const
Class representing the actual attributes for a yield date-period.
Base class for Factory layer.
Definition: FacCloneBom.hpp:22
bool isTripTypeValid(const TripType_T &) const