Go to the documentation of this file.00001
00002
00003
00004
00005 #include <cassert>
00006 #include <sstream>
00007
00008 #include <boost/archive/text_iarchive.hpp>
00009 #include <boost/archive/text_oarchive.hpp>
00010 #include <boost/serialization/access.hpp>
00011
00012 #include <stdair/basic/BasConst_Inventory.hpp>
00013
00014 #include <airsched/bom/OriginDestinationSet.hpp>
00015
00016 namespace AIRSCHED {
00017
00018
00019 OriginDestinationSet::OriginDestinationSet()
00020 : _key (stdair::DEFAULT_ORIGIN), _parent (NULL) {
00021 assert (false);
00022 }
00023
00024
00025 OriginDestinationSet::OriginDestinationSet (const OriginDestinationSet&)
00026 : _key (stdair::DEFAULT_ORIGIN), _parent (NULL) {
00027 assert (false);
00028 }
00029
00030
00031 OriginDestinationSet::OriginDestinationSet (const Key_T& iKey)
00032 : _key (iKey), _parent (NULL) {
00033 }
00034
00035
00036 OriginDestinationSet::~OriginDestinationSet() {
00037 }
00038
00039
00040 std::string OriginDestinationSet::toString() const {
00041 std::ostringstream oStr;
00042 oStr << _key.toString();
00043 return oStr.str();
00044 }
00045
00046
00047 void OriginDestinationSet::serialisationImplementationExport() const {
00048 std::ostringstream oStr;
00049 boost::archive::text_oarchive oa (oStr);
00050 oa << *this;
00051 }
00052
00053
00054 void OriginDestinationSet::serialisationImplementationImport() {
00055 std::istringstream iStr;
00056 boost::archive::text_iarchive ia (iStr);
00057 ia >> *this;
00058 }
00059
00060
00061 template<class Archive>
00062 void OriginDestinationSet::serialize (Archive& ioArchive,
00063 const unsigned int iFileVersion) {
00064 ioArchive & _key;
00065 }
00066
00067
00068
00069 namespace ba = boost::archive;
00070 template
00071 void OriginDestinationSet::serialize<ba::text_oarchive> (ba::text_oarchive&,
00072 unsigned int);
00073 template
00074 void OriginDestinationSet::serialize<ba::text_iarchive> (ba::text_iarchive&,
00075 unsigned int);
00076
00077
00078 }
00079