1.00.26
C++ Standard Airline IT Object Library
Toggle main menu visibility
Loading...
Searching...
No Matches
BomRoot.cpp
Go to the documentation of this file.
1
// //////////////////////////////////////////////////////////////////////
2
// Import section
3
// //////////////////////////////////////////////////////////////////////
4
// STL
5
#include <cassert>
6
#include <sstream>
7
// StdAir
8
#include <
stdair/basic/BasConst_General.hpp
>
9
#include <
stdair/bom/BomManager.hpp
>
10
#include <
stdair/bom/BomRoot.hpp
>
11
#include <
stdair/bom/InventoryKey.hpp
>
12
#include <
stdair/bom/Inventory.hpp
>
13
14
namespace
stdair
{
15
16
// ////////////////////////////////////////////////////////////////////
17
BomRoot::BomRoot
() {
18
assert (
false
);
19
}
20
21
// ////////////////////////////////////////////////////////////////////
22
BomRoot::BomRoot
(
const
BomRoot
& iBomRoot) :
23
_key
(iBomRoot.
_key
),
_frat5CurveHolder
(iBomRoot.
_frat5CurveHolder
),
24
_ffDisutilityCurveHolder
(iBomRoot.
_ffDisutilityCurveHolder
) {
25
}
26
27
// ////////////////////////////////////////////////////////////////////
28
BomRoot::BomRoot
(
const
Key_T
& iKey) :
_key
(iKey) {
29
}
30
31
// ////////////////////////////////////////////////////////////////////
32
BomRoot::~BomRoot
() {
33
}
34
35
// ////////////////////////////////////////////////////////////////////
36
std::string
BomRoot::toString
()
const
{
37
std::ostringstream oStr;
38
oStr <<
_key
.toString();
39
return
oStr.str();
40
}
41
42
// ////////////////////////////////////////////////////////////////////
43
Inventory
*
BomRoot::getInventory
(
const
std::string& iInventoryKeyStr)
const
{
44
Inventory
* oInventory_ptr =
45
BomManager::getObjectPtr<Inventory>
(*
this
, iInventoryKeyStr);
46
return
oInventory_ptr;
47
}
48
49
// ////////////////////////////////////////////////////////////////////
50
Inventory
*
BomRoot::getInventory
(
const
InventoryKey
& iInventoryKey)
const
{
51
return
getInventory
(iInventoryKey.
toString
());
52
}
53
54
}
BasConst_General.hpp
BomManager.hpp
BomRoot.hpp
Inventory.hpp
InventoryKey.hpp
stdair
Handle on the StdAir library context.
Definition
BasChronometer.cpp:9
stdair::BomManager::getObjectPtr
static OBJECT2 * getObjectPtr(const OBJECT1 &, const MapKey_T &)
Definition
BomManager.hpp:241
stdair::BomRoot::_key
Key_T _key
Definition
BomRoot.hpp:191
stdair::BomRoot::Key_T
BomRootKey Key_T
Definition
BomRoot.hpp:42
stdair::BomRoot::~BomRoot
~BomRoot()
Definition
BomRoot.cpp:32
stdair::BomRoot::_frat5CurveHolder
FRAT5CurveHolderStruct _frat5CurveHolder
Definition
BomRoot.hpp:201
stdair::BomRoot::getInventory
Inventory * getInventory(const std::string &iInventoryKeyStr) const
Definition
BomRoot.cpp:43
stdair::BomRoot::toString
std::string toString() const
Definition
BomRoot.cpp:36
stdair::BomRoot::BomRoot
BomRoot()
Definition
BomRoot.cpp:17
stdair::BomRoot::_ffDisutilityCurveHolder
FFDisutilityCurveHolderStruct _ffDisutilityCurveHolder
Definition
BomRoot.hpp:206
stdair::Inventory
Class representing the actual attributes for an airline inventory.
Definition
Inventory.hpp:41
stdair::InventoryKey
Key of a given inventory, made of the airline code.
Definition
InventoryKey.hpp:26
stdair::InventoryKey::toString
const std::string toString() const
Definition
InventoryKey.cpp:46
Generated for StdAir by
1.17.0