00001
00002
00003
00004
00005 #include <stdair/basic/BasConst_General.hpp>
00006 #include <stdair/basic/BasConst_BomDisplay.hpp>
00007 #include <stdair/basic/BasConst_Event.hpp>
00008 #include <stdair/basic/BasConst_Request.hpp>
00009 #include <stdair/basic/BasConst_Inventory.hpp>
00010 #include <stdair/basic/BasConst_BookingClass.hpp>
00011 #include <stdair/basic/BasConst_Yield.hpp>
00012 #include <stdair/basic/BasConst_DefaultObject.hpp>
00013 #include <stdair/basic/BasConst_Period_BOM.hpp>
00014 #include <stdair/basic/BasConst_TravelSolution.hpp>
00015
00016 namespace stdair {
00017
00018
00020 const std::string DEFAULT_BOM_ROOT_KEY (" -- ROOT -- ");
00021
00023 const double DEFAULT_EPSILON_VALUE (0.0001);
00024
00026 const unsigned int DEFAULT_FLIGHT_SPEED (900);
00027
00029 const NbOfFlightDates_T DEFAULT_NB_OF_FLIGHTDATES (0.0);
00030
00032 const Duration_T NULL_BOOST_TIME_DURATION (-1, -1, -1);
00033
00035 const unsigned int DEFAULT_NB_OF_DAYS_IN_A_YEAR (365);
00036
00038 const unsigned int DEFAULT_NUMBER_OF_SUBDIVISIONS (1000);
00039
00040
00042 const DayDuration_T DEFAULT_DAY_DURATION (0);
00043
00045 const DatePeriod_T BOOST_DEFAULT_DATE_PERIOD (Date_T (2007, 1, 1),
00046 Date_T (2007, 1, 1));
00047
00049 const std::string DOW_STR[] =
00050 {"Mon", "Tue", "Wed", "Thu", "Fri", "Sat", "Sun"};
00051
00053 const DOW_String_T DEFAULT_DOW_STRING ("0000000");
00054
00056 const DateOffset_T DEFAULT_DATE_OFFSET (0);
00057
00058
00059
00061 const Date_T DEFAULT_DATE (2010, boost::gregorian::Jan, 1);
00062
00064 const DateTime_T DEFAULT_DATETIME (DEFAULT_DATE, NULL_BOOST_TIME_DURATION);
00065
00067 const Duration_T DEFAULT_EPSILON_DURATION (0, 0, 0, 1);
00068
00070 const Count_T SECONDS_IN_ONE_DAY (86400);
00071
00073 const Count_T MILLISECONDS_IN_ONE_SECOND (1000);
00074
00076 const RandomSeed_T DEFAULT_RANDOM_SEED (120765987);
00077
00078
00080 const AirportCode_T AIRPORT_LHR ("LHR");
00081
00083 const AirportCode_T AIRPORT_SYD ("SYD");
00084
00086 const CityCode_T POS_LHR ("LHR");
00087
00089 const Date_T DATE_20110115 (2011, boost::gregorian::Jan, 15);
00090 const Date_T DATE_20111231 (2011, boost::gregorian::Dec, 31);
00091
00093 const DayDuration_T NO_ADVANCE_PURCHASE (0);
00094
00096 const SaturdayStay_T SATURDAY_STAY (true);
00097
00099 const SaturdayStay_T NO_SATURDAY_STAY (false);
00100
00102 const ChangeFees_T CHANGE_FEES (true);
00103
00105 const ChangeFees_T NO_CHANGE_FEES (false);
00106
00108 const NonRefundable_T NON_REFUNDABLE (true);
00109
00111 const NonRefundable_T No_NON_REFUNDABLE (false);
00112
00114 const SaturdayStay_T DEFAULT_BOM_TREE_SATURDAY_STAY (true);
00115
00117 const ChangeFees_T DEFAULT_BOM_TREE_CHANGE_FEES (true);
00118
00120 const NonRefundable_T DEFAULT_BOM_TREE_NON_REFUNDABLE (true);
00121
00123 const DayDuration_T NO_STAY_DURATION (0);
00124
00126 const AirlineCode_T AIRLINE_CODE_BA ("BA");
00127
00129 const CabinCode_T CABIN_Y ("Y");
00130
00132 const ClassCode_T CLASS_CODE_Y ("Y");
00133
00134
00136 const ClassCode_T CLASS_CODE_Q ("Q");
00137
00138
00140 const AirportCode_T AIRPORT_SIN ("SIN");
00141
00143 const AirportCode_T AIRPORT_BKK ("BKK");
00144
00146 const CityCode_T POS_SIN ("SIN");
00147
00149 const CabinCode_T CABIN_ECO ("Eco");
00150
00152 const FrequentFlyer_T FREQUENT_FLYER_MEMBER ("M");
00153
00154
00156 const ClassCode_T DEFAULT_FAMILY_CODE ("0");
00157
00159 const NbOfAirlines_T DEFAULT_NBOFAIRLINES (0);
00160
00162 const FlightPathCode_T DEFAULT_FLIGHTPATH_CODE ("");
00163
00164
00166 const Distance_T DEFAULT_DISTANCE_VALUE (0);
00167
00169 const ClassCode_T DEFAULT_CLOSED_CLASS_CODE ("CC");
00170
00173 const NbOfBookings_T DEFAULT_CLASS_NB_OF_BOOKINGS (0);
00174
00177 const NbOfBookings_T DEFAULT_CLASS_TOTAL_NB_OF_BOOKINGS (0);
00178
00180 const NbOfBookings_T DEFAULT_CLASS_UNCONSTRAINED_DEMAND (0);
00181
00183 const NbOfBookings_T DEFAULT_CLASS_REMAINING_DEMAND_MEAN (0);
00184
00186 const NbOfBookings_T DEFAULT_CLASS_REMAINING_DEMAND_STANDARD_DEVIATION (0);
00187
00189 const NbOfCancellations_T DEFAULT_CLASS_NB_OF_CANCELLATIONS (0);
00190
00192 const NbOfNoShows_T DEFAULT_CLASS_NB_OF_NOSHOWS (0);
00193
00195 const CabinCapacity_T DEFAULT_CABIN_CAPACITY (0.0);
00196
00198 const CommittedSpace_T DEFAULT_COMMITTED_SPACE (0.0);
00199
00201 const BlockSpace_T DEFAULT_BLOCK_SPACE (0.0);
00202
00204 const Availability_T DEFAULT_NULL_AVAILABILITY (0.0);
00205
00207 const Availability_T DEFAULT_AVAILABILITY (9.0);
00208
00210 const Availability_T MAXIMAL_AVAILABILITY (9999.0);
00211
00212
00213
00216 const CensorshipFlag_T DEFAULT_CLASS_CENSORSHIPFLAG (false);
00217
00220 const CensorshipFlagList_T DEFAULT_CLASS_CENSORSHIPFLAG_LIST =
00221 std::vector<CensorshipFlag_T>();
00222
00224 const BookingLimit_T DEFAULT_CLASS_BOOKING_LIMIT (9999.0);
00225
00227 const AuthorizationLevel_T DEFAULT_CLASS_AUTHORIZATION_LEVEL (9999.0);
00228
00230 const AuthorizationLevel_T DEFAULT_CLASS_MAX_AUTHORIZATION_LEVEL (9999.0);
00231
00233 const AuthorizationLevel_T DEFAULT_CLASS_MIN_AUTHORIZATION_LEVEL (0.0);
00234
00236 const OverbookingRate_T DEFAULT_CLASS_OVERBOOKING_RATE (0.0);
00237
00239 const BookingRatio_T DEFAULT_OND_BOOKING_RATE (0.0);
00240
00242 const Fare_T DEFAULT_FARE_VALUE (0.0);
00243
00245 const Yield_T DEFAULT_CLASS_YIELD_VALUE (0.0);
00246
00248 const Revenue_T DEFAULT_REVENUE_VALUE (0.0);
00249
00251 const Percentage_T DEFAULT_LOAD_FACTOR_VALUE (100.0);
00252
00253
00254
00256 const Yield_T DEFAULT_YIELD_VALUE (0.0);
00257
00259 const Yield_T DEFAULT_YIELD_MAX_VALUE (std::numeric_limits<double>::max());
00260
00262 const NbOfBookings_T DEFAULT_YIELD_NB_OF_BOOKINGS (0.0);
00263
00265 const Identity_T DEFAULT_BOOKING_NUMBER (0);
00266
00268 const NbOfCancellations_T DEFAULT_YIELD_NB_OF_CANCELLATIONS (0.0);
00269
00271 const NbOfNoShows_T DEFAULT_YIELD_NB_OF_NOSHOWS (0.0);
00272
00274 const Availability_T DEFAULT_YIELD_AVAILABILITY (0.0);
00275
00278 const CensorshipFlag_T DEFAULT_YIELD_CENSORSHIPFLAG (false);
00279
00281 const BookingLimit_T DEFAULT_YIELD_BOOKING_LIMIT (0.0);
00282
00284 const OverbookingRate_T DEFAULT_YIELD_OVERBOOKING_RATE (0.0);
00285
00286
00287
00289 const Fare_T DEFAULT_OND_FARE_VALUE (0.0);
00290
00291
00292
00294 const EventQueueID_T DEFAULT_EVENT_QUEUE_ID ("EQ01");
00295
00297 const Count_T DEFAULT_PROGRESS_STATUS (0);
00298
00301 const Date_T DEFAULT_EVENT_OLDEST_DATE (2008, boost::gregorian::Jan, 1);
00302
00305 const DateTime_T DEFAULT_EVENT_OLDEST_DATETIME (DEFAULT_EVENT_OLDEST_DATE,
00306 NULL_BOOST_TIME_DURATION);
00307
00308
00309
00311 const PartySize_T DEFAULT_PARTY_SIZE (1);
00312
00314 const DayDuration_T DEFAULT_STAY_DURATION (7);
00315
00317 const WTP_T DEFAULT_WTP (1000.0);
00318
00320 const Date_T DEFAULT_PREFERRED_DEPARTURE_DATE (DEFAULT_DEPARTURE_DATE);
00321
00323 const Duration_T DEFAULT_PREFERRED_DEPARTURE_TIME (8, 0, 0);
00324
00326 const DateOffset_T DEFAULT_ADVANCE_PURCHASE (22);
00327
00329 const Date_T DEFAULT_REQUEST_DATE (DEFAULT_PREFERRED_DEPARTURE_DATE
00330 - DEFAULT_ADVANCE_PURCHASE);
00331
00333 const Duration_T DEFAULT_REQUEST_TIME (8, 0, 0);
00334
00336 const DateTime_T DEFAULT_REQUEST_DATE_TIME (DEFAULT_REQUEST_DATE,
00337 DEFAULT_REQUEST_TIME);
00338
00340 const CabinCode_T DEFAULT_PREFERRED_CABIN ("M");
00341
00343 const CityCode_T DEFAULT_POS ("ALL");
00344
00346 const ChannelLabel_T DEFAULT_CHANNEL ("DC");
00347
00349 const ChannelLabel_T CHANNEL_DN ("DN");
00350
00352 const ChannelLabel_T CHANNEL_IN ("IN");
00353
00355 const TripType_T TRIP_TYPE_ONE_WAY ("OW");
00356
00358 const TripType_T TRIP_TYPE_ROUND_TRIP ("RT");
00359
00361 const TripType_T TRIP_TYPE_INBOUND ("RI");
00362
00364 const TripType_T TRIP_TYPE_OUTBOUND ("RO");
00365
00367 const FrequentFlyer_T DEFAULT_FF_TIER ("N");
00368
00370 const PriceValue_T DEFAULT_VALUE_OF_TIME (100.0);
00371
00372
00373
00375 const Duration_T DEFAULT_MINIMAL_CONNECTION_TIME (0, 30, 0);
00376
00378 const Duration_T DEFAULT_MAXIMAL_CONNECTION_TIME (24, 0, 0);
00379
00381 const MatchingIndicator_T DEFAULT_MATCHING_INDICATOR (0.0);
00382
00384 const PriceCurrency_T DEFAULT_CURRENCY ("EUR");
00385
00387 const AvailabilityStatus_T DEFAULT_AVAILABILITY_STATUS (false);
00388
00390 const Date_T DEFAULT_DICO_STUDIED_DATE;
00391
00392
00394 const AirlineCode_T DEFAULT_AIRLINE_CODE ("XX");
00395
00397 const AirlineCode_T DEFAULT_NULL_AIRLINE_CODE ("");
00398
00400 const AirlineCodeList_T DEFAULT_AIRLINE_CODE_LIST;
00401
00403 const FlightNumber_T DEFAULT_FLIGHT_NUMBER (9999);
00404
00406 const GuillotineNumber_T DEFAULT_GUILLOTINE_NUMBER (9999);
00407
00409 const Date_T DEFAULT_DEPARTURE_DATE (1900, boost::gregorian::Jan, 1);
00410
00412 const AirportCode_T DEFAULT_AIRPORT_CODE ("XXX");
00413
00415 const AirportCode_T DEFAULT_NULL_AIRPORT_CODE ("");
00416
00418 const AirportCode_T DEFAULT_ORIGIN ("XXX");
00419
00421 const AirportCode_T DEFAULT_DESTINATION ("XXX");
00422
00424 const CabinCode_T DEFAULT_CABIN_CODE ("X");
00425
00427 const FamilyCode_T DEFAULT_FARE_FAMILY_CODE ("EcoSaver");
00428
00430 const FamilyCode_T DEFAULT_NULL_FARE_FAMILY_CODE ("NoFF");
00431
00433 const ClassCode_T DEFAULT_CLASS_CODE ("X");
00434
00436 const ClassCode_T DEFAULT_NULL_CLASS_CODE ("");
00437
00439 const ClassList_StringList_T DEFAULT_CLASS_CODE_LIST;
00440
00442 const BidPrice_T DEFAULT_BID_PRICE (0.0);
00443
00445 const BidPriceVector_T DEFAULT_BID_PRICE_VECTOR = std::vector<BidPrice_T>();
00446
00450 const unsigned short MAXIMAL_NUMBER_OF_LEGS_IN_FLIGHT (7);
00451
00454 const unsigned short MAXIMAL_NUMBER_OF_SEGMENTS_IN_OND (3);
00455
00457 const SeatIndex_T DEFAULT_SEAT_INDEX (1);
00458
00460 const std::string DEFAULT_FARE_FAMILY_VALUE_TYPE ("FF");
00461
00463 const std::string DEFAULT_SEGMENT_CABIN_VALUE_TYPE ("SC");
00464
00466 const int DEFAULT_MAX_DTD = 365;
00467
00469 const DCPList_T DEFAULT_DCP_LIST = DefaultDCPList::init();
00470 DCPList_T DefaultDCPList::init() {
00471 DCPList_T oDCPList;
00472
00473 oDCPList.push_back (63);oDCPList.push_back (56);oDCPList.push_back (49);
00474 oDCPList.push_back (42);oDCPList.push_back (35);oDCPList.push_back (31);
00475 oDCPList.push_back (27);oDCPList.push_back (23);oDCPList.push_back (19);
00476 oDCPList.push_back (16);oDCPList.push_back (13);oDCPList.push_back (10);
00477 oDCPList.push_back (7); oDCPList.push_back (5); oDCPList.push_back (3);
00478 oDCPList.push_back (1); oDCPList.push_back (0);
00479
00480
00481
00482
00483
00484 return oDCPList;
00485 }
00487 const DTDFratMap_T DEFAULT_DTD_FRAT5COEF_MAP =
00488 DefaultDtdFratMap::init();
00489 DTDFratMap_T DefaultDtdFratMap::init() {
00490 DTDFratMap_T oDFCMap;
00491 oDFCMap[71] = 2.50583571429; oDFCMap[63] = 2.55994571429;
00492 oDFCMap[56] = 2.60841857143; oDFCMap[49] = 2.68888;
00493 oDFCMap[42] = 2.78583714286; oDFCMap[35] = 2.89091428571;
00494 oDFCMap[31] = 2.97871428571; oDFCMap[28] = 3.05521428571;
00495 oDFCMap[24] = 3.15177142857; oDFCMap[21] = 3.22164285714;
00496 oDFCMap[17] = 3.32237142857; oDFCMap[14] = 3.38697142857;
00497 oDFCMap[10] = 3.44204285714; oDFCMap[7] = 3.46202857143;
00498 oDFCMap[5] = 3.47177142857; oDFCMap[3] = 3.4792;
00499 oDFCMap[1] = 3.48947142857;
00500 return oDFCMap;
00501 }
00502
00504 const DTDProbMap_T DEFAULT_DTD_PROB_MAP =
00505 DefaultDtdProbMap::init();
00506 DTDProbMap_T DefaultDtdProbMap::init() {
00507 DTDProbMap_T oDPMap;
00508 oDPMap[-330] = 0; oDPMap[-150] = 0.1; oDPMap[-92] = 0.2;
00509 oDPMap[-55] = 0.3; oDPMap[-34] = 0.4; oDPMap[-21] = 0.5;
00510 oDPMap[-12] = 0.6; oDPMap[-6] = 0.7; oDPMap[-3] = 0.8;
00511 oDPMap[-1] = 0.9; oDPMap[0] = 1.0;
00512 return oDPMap;
00513 }
00514
00515
00516
00519 const std::string DEFAULT_KEY_FLD_DELIMITER (";");
00520
00523 const std::string DEFAULT_KEY_SUB_FLD_DELIMITER (",");
00524
00526 const boost::char_separator<char> DEFAULT_KEY_TOKEN_DELIMITER (";, ");
00527
00529 const OnDStringList_T DEFAULT_OND_STRING_LIST;
00530
00531
00532
00535 const std::string DISPLAY_LEVEL_STRING_ARRAY[51] =
00536 { "", " ", " ", " ",
00537 " ", " ", " ", " ",
00538 " ", " ", " ",
00539 " ", " ",
00540 " ", " ",
00541 " ", " ",
00542 " ",
00543 " ",
00544 " ",
00545 " ",
00546 " ",
00547 " ",
00548 " ",
00549 " ",
00550 " ",
00551 " ",
00552 " ",
00553 " ",
00554 " ",
00555 " ",
00556 " ",
00557 " ",
00558 " ",
00559 " ",
00560 " ",
00561 " ",
00562 " ",
00563 " ",
00564 " ",
00565 " ",
00566 " ",
00567 " ",
00568 " ",
00569 " ",
00570 " ",
00571 " ",
00572 " ",
00573 " ",
00574 " ",
00575 " " };
00576
00577
00578 }