1.01.17
C++ Simulated Airline Travel Solution Provider (TSP) Library
Toggle main menu visibility
Loading...
Searching...
No Matches
ReachableUniverse.cpp
Go to the documentation of this file.
1
// //////////////////////////////////////////////////////////////////////
2
// Import section
3
// //////////////////////////////////////////////////////////////////////
4
// STL
5
#include <cassert>
6
#include <sstream>
7
// Boost.Serialization
8
#include <boost/archive/text_iarchive.hpp>
9
#include <boost/archive/text_oarchive.hpp>
10
#include <boost/serialization/access.hpp>
11
// StdAir
12
#include <stdair/basic/BasConst_Inventory.hpp>
13
// AirTSP
14
#include <
airtsp/bom/ReachableUniverse.hpp
>
15
#include <
airtsp/bom/SegmentPathPeriod.hpp
>
16
17
namespace
AIRTSP
{
18
19
// ////////////////////////////////////////////////////////////////////
20
ReachableUniverse::ReachableUniverse
()
21
: _key (stdair::DEFAULT_ORIGIN), _parent (NULL) {
22
assert (
false
);
23
}
24
25
// ////////////////////////////////////////////////////////////////////
26
ReachableUniverse::ReachableUniverse (
const
ReachableUniverse&)
27
: _key (
stdair
::DEFAULT_ORIGIN), _parent (NULL) {
28
assert (
false
);
29
}
30
31
// ////////////////////////////////////////////////////////////////////
32
ReachableUniverse::ReachableUniverse
(
const
Key_T
& iKey)
33
:
_key
(iKey),
_parent
(NULL) {
34
}
35
36
// ////////////////////////////////////////////////////////////////////
37
ReachableUniverse::~ReachableUniverse
() {
38
}
39
40
// ////////////////////////////////////////////////////////////////////
41
std::string
ReachableUniverse::toString
()
const
{
42
std::ostringstream oStr;
43
oStr <<
_key
.toString();
44
return
oStr.str();
45
}
46
47
// ////////////////////////////////////////////////////////////////////
48
void
ReachableUniverse::serialisationImplementationExport()
const
{
49
std::ostringstream oStr;
50
boost::archive::text_oarchive oa (oStr);
51
oa << *
this
;
52
}
53
54
// ////////////////////////////////////////////////////////////////////
55
void
ReachableUniverse::serialisationImplementationImport() {
56
std::istringstream iStr;
57
boost::archive::text_iarchive ia (iStr);
58
ia >> *
this
;
59
}
60
61
// ////////////////////////////////////////////////////////////////////
62
template
<
class
Archive>
63
void
ReachableUniverse::serialize
(Archive& ioArchive,
64
const
unsigned
int
iFileVersion) {
65
ioArchive &
_key
;
66
}
67
68
// ////////////////////////////////////////////////////////////////////
69
// Explicit template instantiation
70
namespace
ba = boost::archive;
71
template
72
void
ReachableUniverse::serialize<ba::text_oarchive>
(ba::text_oarchive&,
73
unsigned
int
);
74
template
75
void
ReachableUniverse::serialize<ba::text_iarchive>
(ba::text_iarchive&,
76
unsigned
int
);
77
// ////////////////////////////////////////////////////////////////////
78
79
}
80
ReachableUniverse.hpp
SegmentPathPeriod.hpp
AIRTSP::ReachableUniverse::_parent
stdair::BomAbstract * _parent
Definition
ReachableUniverse.hpp:179
AIRTSP::ReachableUniverse::~ReachableUniverse
~ReachableUniverse()
Definition
ReachableUniverse.cpp:37
AIRTSP::ReachableUniverse::serialize
void serialize(Archive &ar, const unsigned int iFileVersion)
Definition
ReachableUniverse.cpp:63
AIRTSP::ReachableUniverse::Key_T
ReachableUniverseKey Key_T
Definition
ReachableUniverse.hpp:55
AIRTSP::ReachableUniverse::_key
Key_T _key
Definition
ReachableUniverse.hpp:174
AIRTSP::ReachableUniverse::toString
std::string toString() const
Definition
ReachableUniverse.cpp:41
AIRTSP::ReachableUniverse::ReachableUniverse
ReachableUniverse(const Key_T &)
Definition
ReachableUniverse.cpp:32
AIRTSP
Definition
AIRTSP_Service.hpp:23
stdair
Forward declarations.
Definition
AIRTSP_Service.hpp:14
Generated on
for AirTSP by
1.17.0