StdAir Logo  1.00.12
C++ Standard Airline IT Object Library
AirportPair.hpp
Go to the documentation of this file.
1#ifndef __STDAIR_BOM_AIRPORTPAIR_HPP
2#define __STDAIR_BOM_AIRPORTPAIR_HPP
3
4// //////////////////////////////////////////////////////////////////////
5// Import section
6// //////////////////////////////////////////////////////////////////////
7// STDAIR
11
12// Forward declaration
13namespace stdair {
14
18 class AirportPair : public BomAbstract {
19 template <typename BOM> friend class FacBom;
20 template <typename BOM> friend class FacCloneBom;
21 friend class FacBomManager;
22
23 public:
24 // //////////// Type definitions //////////////
29
30 public:
31 // /////////// Display support methods /////////
37 void toStream (std::ostream& ioOut) const {
38 ioOut << toString();
39 }
40
46 void fromStream (std::istream& ioIn) {
47 }
48
52 std::string toString() const;
53
57 const std::string describeKey() const {
58 return _key.toString();
59 }
60
61 public:
62 // ////////// Getters ////////////
66 const Key_T& getKey() const {
67 return _key;
68 }
69
74 return _key.getBoardingPoint();
75 }
76
80 const AirportCode_T& getOffPoint() const {
81 return _key.getOffPoint();
82 }
83
87 BomAbstract* const getParent() const {
88 return _parent;
89 }
90
94 const HolderMap_T& getHolderMap() const {
95 return _holderMap;
96 }
97
98 protected:
99 // ////////// Constructors and destructors /////////
103 AirportPair (const Key_T&);
107 virtual ~AirportPair();
108
109 private:
113 AirportPair();
117 AirportPair (const AirportPair&);
118
119 protected:
120 // ///////////// Attributes /////////////
125
130
135
136 };
137
138}
139#endif // __STDAIR_BOM_AIRPORTPAIR_HPP
140
Handle on the StdAir library context.
std::map< const std::type_info *, BomAbstract * > HolderMap_T
Definition: BomAbstract.hpp:63
LocationCode_T AirportCode_T
Class representing the actual attributes for an airport-pair.
Definition: AirportPair.hpp:18
BomAbstract * _parent
void toStream(std::ostream &ioOut) const
Definition: AirportPair.hpp:37
BomAbstract *const getParent() const
Definition: AirportPair.hpp:87
const AirportCode_T & getOffPoint() const
Definition: AirportPair.hpp:80
std::string toString() const
Definition: AirportPair.cpp:36
const std::string describeKey() const
Definition: AirportPair.hpp:57
HolderMap_T _holderMap
virtual ~AirportPair()
Definition: AirportPair.cpp:32
const AirportCode_T & getBoardingPoint() const
Definition: AirportPair.hpp:73
const HolderMap_T & getHolderMap() const
Definition: AirportPair.hpp:94
const Key_T & getKey() const
Definition: AirportPair.hpp:66
AirportPairKey Key_T
Definition: AirportPair.hpp:28
void fromStream(std::istream &ioIn)
Definition: AirportPair.hpp:46
Key of airport-pair.
const std::string toString() const
const stdair::AirportCode_T & getOffPoint() const
const stdair::AirportCode_T & getBoardingPoint() const
Base class for the Business Object Model (BOM) layer.
Definition: BomAbstract.hpp:24
Base class for Factory layer.
Definition: FacBom.hpp:22
Utility class for linking StdAir-based objects.
Base class for Factory layer.
Definition: FacCloneBom.hpp:22