This page contains some tutorial examples that will help you getting started using AirRAC. Most examples show how to construct some simple business objects, i.e., instances of the so-named Business Object Model (BOM).
First, a BOM root object (i.e., a root for all the classes in the project) is instantiated by the airrac::AIRRAC_ServiceContext
context object, when the airrac::AIRRAC_Service
is itself instantiated. The corresponding AirRAC
type (class) is airrac::BomRoot
.
An airline inventory object can then be instantiated. Let us give it the "BA" airline code (corresponding to British Airways) as the object key. That is, an object (let us name it lBAKey
) of type (class) airrac::InventoryKey
has first to be instantiated.
Thanks to that key, an airline inventory object, i.e. of type (class) airrac::Inventory
, can be instantiated. Let us name that airline inventory object lBAInv
.
See the corresponding full program (cmd_bom_manager_cpp) for more details.
... and browsed:
See the corresponding full program (bom_display_cpp) for more details.
[D]/home/user/dev/sim/airrac/airracgithub/airrac/batches/airrac.cpp:184: Welcome to AirRAC
[D]/home/user/dev/sim/airrac/airracgithub/airrac/command/YieldParserHelper.cpp:493: Parsing yield input file: /home/user/dev/deliveries/stdair-0.36.2/share/stdair/samples/yieldstore01.csv
[D]/home/user/dev/sim/airrac/airracgithub/airrac/command/YieldParserHelper.cpp:326: YieldRule: 1, SIN-BKK (ALL), DC, [2010-Jan-15/2011-Jan-01] - [00:00:00/23:59:00], Y, 200 EUR, SQ / Y
[D]/home/user/dev/sim/airrac/airracgithub/airrac/command/YieldParserHelper.cpp:326: YieldRule: 2, SIN-HND (ALL), DC, [2010-Jan-15/2011-Jan-01] - [00:00:00/23:59:00], Y, 200 EUR, SQ / Y
[D]/home/user/dev/sim/airrac/airracgithub/airrac/command/YieldParserHelper.cpp:326: YieldRule: 3, SIN-NCE (ALL), DC, [2010-Jan-15/2011-Jan-01] - [00:00:00/23:59:00], Y, 1200 EUR, SQ / Y - AF / YLMN
[D]/home/user/dev/sim/airrac/airracgithub/airrac/command/YieldParserHelper.cpp:326: YieldRule: 4, SIN-BKK (ALL), DC, [2010-Jan-15/2011-Jan-01] - [00:00:00/23:59:00], Y, 300 EUR, SQ / Y
[D]/home/user/dev/sim/airrac/airracgithub/airrac/command/YieldParserHelper.cpp:326: YieldRule: 5, SIN-HND (ALL), DC, [2010-Jan-15/2011-Jan-01] - [00:00:00/23:59:00], Y, 300 EUR, SQ / Y
[D]/home/user/dev/sim/airrac/airracgithub/airrac/command/YieldParserHelper.cpp:326: YieldRule: 6, SIN-NCE (ALL), DC, [2010-Jan-15/2011-Jan-01] - [00:00:00/23:59:00], Y, 1500 EUR, SQ / Y - AF / YLMN
[D]/home/user/dev/sim/airrac/airracgithub/airrac/command/YieldParserHelper.cpp:541: Parsing of yield input file: /home/user/dev/deliveries/stdair-0.36.2/share/stdair/samples/yieldstore01.csv succeeded
[D]/home/user/dev/sim/airrac/airracgithub/airrac/batches/airrac.cpp:205: BOM tree:
===============================================================
BomRoot: -- ROOT --
===============================================================
+++++++++++++++++++++++++++++++++++++++++++++++++
AirportPair: SIN, BKK
+++++++++++++++++++++++++++++++++++++++++++++++++
------------------------------------------
DatePeriod: [2010-Jan-15/2011-Jan-01]
------------------------------------------
******************************************
PosChannel: ALL, DC
******************************************
----------------------------------------
TimePeriod: 00:00:00-23:59:00
----------------------------------------
--------------------------------------
Fare/yield-Features: OW -- Y
--------------------------------------
------------------------------------
AirlineClassList: SQ Y
------------------------------------
--------------------------------------
Fare/yield-Features: RT -- Y
--------------------------------------
------------------------------------
AirlineClassList: SQ Y
------------------------------------
+++++++++++++++++++++++++++++++++++++++++++++++++
AirportPair: SIN, HND
+++++++++++++++++++++++++++++++++++++++++++++++++
------------------------------------------
DatePeriod: [2010-Jan-15/2011-Jan-01]
------------------------------------------
******************************************
PosChannel: ALL, DC
******************************************
----------------------------------------
TimePeriod: 00:00:00-23:59:00
----------------------------------------
--------------------------------------
Fare/yield-Features: OW -- Y
--------------------------------------
------------------------------------
AirlineClassList: SQ Y
------------------------------------
--------------------------------------
Fare/yield-Features: RT -- Y
--------------------------------------
------------------------------------
AirlineClassList: SQ Y
------------------------------------
+++++++++++++++++++++++++++++++++++++++++++++++++
AirportPair: SIN, NCE
+++++++++++++++++++++++++++++++++++++++++++++++++
------------------------------------------
DatePeriod: [2010-Jan-15/2011-Jan-01]
------------------------------------------
******************************************
PosChannel: ALL, DC
******************************************
----------------------------------------
TimePeriod: 00:00:00-23:59:00
----------------------------------------
--------------------------------------
Fare/yield-Features: OW -- Y
--------------------------------------
------------------------------------
AirlineClassList: SQ Y, AF YLMN
------------------------------------
--------------------------------------
Fare/yield-Features: RT -- Y
--------------------------------------
------------------------------------
AirlineClassList: SQ Y, AF YLMN
------------------------------------
[D]/home/user/dev/sim/airrac/airracgithub/airrac/batches/airrac.cpp:210: Travel solutions:
[0] [0] BA, 9, 2011-06-10, LHR, SYD, 21:45 --- Q, 900, 1 1 1 --- [0] Q:8
See the corresponding full program (batch_airrac_cpp) for more details.