00001 #ifndef __STDAIR_BOM_FLIGHTPERIOD_HPP 00002 #define __STDAIR_BOM_FLIGHTPERIOD_HPP 00003 00004 // ////////////////////////////////////////////////////////////////////// 00005 // Import section 00006 // ////////////////////////////////////////////////////////////////////// 00007 // STDAIR 00008 #include <stdair/bom/BomAbstract.hpp> 00009 #include <stdair/bom/FlightPeriodKey.hpp> 00010 #include <stdair/bom/FlightPeriodTypes.hpp> 00011 00012 namespace stdair { 00013 00015 class FlightPeriod : public BomAbstract { 00016 template <typename BOM> friend class FacBom; 00017 friend class FacBomManager; 00018 00019 public: 00020 // Type definitions. 00022 typedef FlightPeriodKey Key_T; 00023 00024 public: 00025 // /////////// Getters /////////////// 00027 const Key_T& getKey () const { return _key; } 00028 00030 BomAbstract* const getParent() const { return _parent; } 00031 00033 const FlightNumber_T& getFlightNumber () const { 00034 return _key.getFlightNumber(); 00035 } 00036 00038 const PeriodStruct& getPeriod () const { return _key.getPeriod(); } 00039 00041 const HolderMap_T& getHolderMap() const { return _holderMap; } 00042 00043 00044 public: 00045 // /////////// Display support methods ///////// 00048 void toStream (std::ostream& ioOut) const { ioOut << toString(); } 00049 00052 void fromStream (std::istream& ioIn) { } 00053 00055 std::string toString() const; 00056 00058 const std::string describeKey() const { return _key.toString(); } 00059 00060 protected: 00062 FlightPeriod (const Key_T&); 00063 FlightPeriod (const FlightPeriod&); 00065 ~FlightPeriod(); 00066 00067 protected: 00068 // Attributes 00069 Key_T _key; 00070 BomAbstract* _parent; 00071 HolderMap_T _holderMap; 00072 }; 00073 00074 } 00075 #endif // __STDAIR_BOM_FLIGHTPERIOD_HPP 00076