StdAir Logo  0.45.1
C++ Standard Airline IT Object Library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
stdair::BookingClass Class Reference

#include <stdair/bom/BookingClass.hpp>

+ Inheritance diagram for stdair::BookingClass:

Public Types

typedef BookingClassKey Key_T

Public Member Functions

const Key_TgetKey () const
const ClassCode_TgetClassCode () const
BomAbstract *const getParent () const
const HolderMap_TgetHolderMap () const
const SubclassCode_TgetSubclassCode () const
const AuthorizationLevel_TgetAuthorizationLevel () const
const ProtectionLevel_TgetProtection () const
const ProtectionLevel_TgetCumulatedProtection () const
const BookingLimit_TgetCumulatedBookingLimit () const
const NbOfSeats_TgetNegotiatedSpace () const
const OverbookingRate_TgetNoShowPercentage () const
const OverbookingRate_TgetCancellationPercentage () const
const NbOfBookings_TgetNbOfBookings () const
const NbOfBookings_TgetNbOfGroupBookings () const
const NbOfBookings_TgetNbOfPendingGroupBookings () const
const NbOfBookings_TgetNbOfStaffBookings () const
const NbOfBookings_TgetNbOfWLBookings () const
const NbOfCancellations_TgetNbOfCancellations () const
const NbOfBookings_TgetETB () const
const Availability_TgetNetClassAvailability () const
const Availability_TgetSegmentAvailability () const
const Availability_TgetNetRevenueAvailability () const
const Yield_TgetYield () const
const MeanValue_TgetMean () const
const StdDevValue_TgetStdDev () const
const GeneratedDemandVector_TgetGeneratedDemandVector () const
void setCumulatedProtection (const ProtectionLevel_T &iPL)
void setProtection (const ProtectionLevel_T &iPL)
void setCumulatedBookingLimit (const BookingLimit_T &iBL)
void setAuthorizationLevel (const AuthorizationLevel_T &iAU)
void setSegmentAvailability (const Availability_T &iAvl)
void setYield (const Yield_T &iYield)
void setMean (const MeanValue_T &iMean)
void setStdDev (const StdDevValue_T &iStdDev)
void toStream (std::ostream &ioOut) const
void fromStream (std::istream &ioIn)
std::string toString () const
const std::string describeKey () const
void sell (const NbOfBookings_T &)
void cancel (const NbOfBookings_T &)
void generateDemandSamples (const int &)
void generateDemandSamples (const int &, const RandomSeed_T &)

Protected Member Functions

 BookingClass (const Key_T &)
virtual ~BookingClass ()

Protected Attributes

Key_T _key
BomAbstract_parent
HolderMap_T _holderMap
SubclassCode_T _subclassCode
ProtectionLevel_T _cumulatedProtection
ProtectionLevel_T _protection
BookingLimit_T _cumulatedBookingLimit
AuthorizationLevel_T _au
NbOfSeats_T _nego
OverbookingRate_T _noShowPercentage
OverbookingRate_T _cancellationPercentage
NbOfBookings_T _nbOfBookings
NbOfBookings_T _groupNbOfBookings
NbOfBookings_T _groupPendingNbOfBookings
NbOfBookings_T _staffNbOfBookings
NbOfBookings_T _wlNbOfBookings
NbOfCancellations_T _nbOfCancellations
NbOfBookings_T _etb
Availability_T _netClassAvailability
Availability_T _segmentAvailability
Availability_T _netRevenueAvailability
Yield_T _yield
MeanValue_T _mean
StdDevValue_T _stdDev
GeneratedDemandVector_T _generatedDemandVector

Friends

class FacBom
class FacBomManager

Detailed Description

Class representing the actual attributes for an airline booking class.

Definition at line 24 of file BookingClass.hpp.

Member Typedef Documentation

Definition allowing to retrieve the associated BOM key type.

Definition at line 31 of file BookingClass.hpp.

Constructor & Destructor Documentation

stdair::BookingClass::BookingClass ( const Key_T iKey)
protected

Constructor.

Definition at line 27 of file BookingClass.cpp.

stdair::BookingClass::~BookingClass ( )
protectedvirtual

Destructor.

Definition at line 39 of file BookingClass.cpp.

Member Function Documentation

const Key_T& stdair::BookingClass::getKey ( ) const
inline

Get the booking class key.

Definition at line 36 of file BookingClass.hpp.

References _key.

const ClassCode_T& stdair::BookingClass::getClassCode ( ) const
inline

Get the booking code (part of the primary key).

Definition at line 41 of file BookingClass.hpp.

References _key, and stdair::BookingClassKey::getClassCode().

BomAbstract* const stdair::BookingClass::getParent ( ) const
inline

Get the parent object.

Definition at line 46 of file BookingClass.hpp.

References _parent.

const HolderMap_T& stdair::BookingClass::getHolderMap ( ) const
inline

Get the map of children holders.

Definition at line 51 of file BookingClass.hpp.

References _holderMap.

const SubclassCode_T& stdair::BookingClass::getSubclassCode ( ) const
inline

Get teh sub-class code.

Definition at line 56 of file BookingClass.hpp.

References _subclassCode.

const AuthorizationLevel_T& stdair::BookingClass::getAuthorizationLevel ( ) const
inline

Get the authorisation level (AU, i.e., cumulated protection).

Definition at line 61 of file BookingClass.hpp.

References _au.

const ProtectionLevel_T& stdair::BookingClass::getProtection ( ) const
inline

Get the protection.

Definition at line 66 of file BookingClass.hpp.

References _protection.

const ProtectionLevel_T& stdair::BookingClass::getCumulatedProtection ( ) const
inline

Get the cumulated protection.

Definition at line 71 of file BookingClass.hpp.

References _cumulatedProtection.

const BookingLimit_T& stdair::BookingClass::getCumulatedBookingLimit ( ) const
inline

Get the cumulated booking limit.

Definition at line 76 of file BookingClass.hpp.

References _cumulatedBookingLimit.

const NbOfSeats_T& stdair::BookingClass::getNegotiatedSpace ( ) const
inline

Get the negotiated space.

Definition at line 81 of file BookingClass.hpp.

References _nego.

const OverbookingRate_T& stdair::BookingClass::getNoShowPercentage ( ) const
inline

Get the no-show rate.

Definition at line 86 of file BookingClass.hpp.

References _noShowPercentage.

const OverbookingRate_T& stdair::BookingClass::getCancellationPercentage ( ) const
inline

Get the cancellation rate.

Definition at line 91 of file BookingClass.hpp.

References _cancellationPercentage.

const NbOfBookings_T& stdair::BookingClass::getNbOfBookings ( ) const
inline

Get the number of bookings.

Definition at line 96 of file BookingClass.hpp.

References _nbOfBookings.

const NbOfBookings_T& stdair::BookingClass::getNbOfGroupBookings ( ) const
inline

Get the number of group bookings.

Definition at line 101 of file BookingClass.hpp.

References _groupNbOfBookings.

const NbOfBookings_T& stdair::BookingClass::getNbOfPendingGroupBookings ( ) const
inline

Get the number of pending group bookings.

Definition at line 106 of file BookingClass.hpp.

References _groupPendingNbOfBookings.

const NbOfBookings_T& stdair::BookingClass::getNbOfStaffBookings ( ) const
inline

Get the number of staff bookings.

Definition at line 111 of file BookingClass.hpp.

References _staffNbOfBookings.

const NbOfBookings_T& stdair::BookingClass::getNbOfWLBookings ( ) const
inline

Get the number of wait-list bookings.

Definition at line 116 of file BookingClass.hpp.

References _wlNbOfBookings.

const NbOfCancellations_T& stdair::BookingClass::getNbOfCancellations ( ) const
inline

Get the number of cancellations.

Definition at line 121 of file BookingClass.hpp.

References _nbOfCancellations.

const NbOfBookings_T& stdair::BookingClass::getETB ( ) const
inline

Get the expected number of passengers to board (ETB).

Definition at line 126 of file BookingClass.hpp.

References _etb.

const Availability_T& stdair::BookingClass::getNetClassAvailability ( ) const
inline

Get the net segment class availability.

Definition at line 131 of file BookingClass.hpp.

References _netClassAvailability.

const Availability_T& stdair::BookingClass::getSegmentAvailability ( ) const
inline

Get the segment class availability.

Definition at line 136 of file BookingClass.hpp.

References _segmentAvailability.

const Availability_T& stdair::BookingClass::getNetRevenueAvailability ( ) const
inline

Net revenue availability.

Definition at line 141 of file BookingClass.hpp.

References _netRevenueAvailability.

const Yield_T& stdair::BookingClass::getYield ( ) const
inline

Yield.

Definition at line 146 of file BookingClass.hpp.

References _yield.

const MeanValue_T& stdair::BookingClass::getMean ( ) const
inline

Demand distribution.

Definition at line 149 of file BookingClass.hpp.

References _mean.

const StdDevValue_T& stdair::BookingClass::getStdDev ( ) const
inline

Definition at line 150 of file BookingClass.hpp.

References _stdDev.

const GeneratedDemandVector_T& stdair::BookingClass::getGeneratedDemandVector ( ) const
inline

Generated demand vector.

Definition at line 153 of file BookingClass.hpp.

References _generatedDemandVector.

Referenced by stdair::VirtualClassStruct::getGeneratedDemandVector().

void stdair::BookingClass::setCumulatedProtection ( const ProtectionLevel_T iPL)
inline

Cumulated protection.

Definition at line 160 of file BookingClass.hpp.

References _cumulatedProtection.

void stdair::BookingClass::setProtection ( const ProtectionLevel_T iPL)
inline

Protection.

Definition at line 165 of file BookingClass.hpp.

References _protection.

void stdair::BookingClass::setCumulatedBookingLimit ( const BookingLimit_T iBL)
inline

Cumulated booking limit.

Definition at line 170 of file BookingClass.hpp.

References _cumulatedBookingLimit.

void stdair::BookingClass::setAuthorizationLevel ( const AuthorizationLevel_T iAU)
inline

Authorization level.

Definition at line 175 of file BookingClass.hpp.

References _au.

void stdair::BookingClass::setSegmentAvailability ( const Availability_T iAvl)
inline

Set availability.

Definition at line 180 of file BookingClass.hpp.

References _segmentAvailability.

void stdair::BookingClass::setYield ( const Yield_T iYield)
inline

Yield.

Definition at line 185 of file BookingClass.hpp.

References _yield.

void stdair::BookingClass::setMean ( const MeanValue_T iMean)
inline

Demand distribution.

Definition at line 188 of file BookingClass.hpp.

References _mean.

void stdair::BookingClass::setStdDev ( const StdDevValue_T iStdDev)
inline

Definition at line 189 of file BookingClass.hpp.

References _stdDev.

void stdair::BookingClass::toStream ( std::ostream &  ioOut) const
inlinevirtual

Dump a Business Object into an output stream.

Parameters
ostream&the output stream.

Implements stdair::BomAbstract.

Definition at line 195 of file BookingClass.hpp.

References toString().

void stdair::BookingClass::fromStream ( std::istream &  ioIn)
inlinevirtual

Read a Business Object from an input stream.

Parameters
istream&the input stream.

Implements stdair::BomAbstract.

Definition at line 201 of file BookingClass.hpp.

std::string stdair::BookingClass::toString ( ) const
virtual

Get the serialised version of the Business Object.

Implements stdair::BomAbstract.

Definition at line 43 of file BookingClass.cpp.

References describeKey().

Referenced by toStream().

const std::string stdair::BookingClass::describeKey ( ) const
inline

Get a string describing the key.

Definition at line 208 of file BookingClass.hpp.

References _key, and stdair::BookingClassKey::toString().

Referenced by toString().

void stdair::BookingClass::sell ( const NbOfBookings_T iNbOfBookings)

Register a sale.

Definition at line 50 of file BookingClass.cpp.

References _nbOfBookings.

void stdair::BookingClass::cancel ( const NbOfBookings_T iNbOfCancellations)

Register a cancellation.

Definition at line 55 of file BookingClass.cpp.

References _nbOfBookings, and _nbOfCancellations.

void stdair::BookingClass::generateDemandSamples ( const int &  K)

Generate demand samples for Monte-Carlo method with the default random seed.

Definition at line 61 of file BookingClass.cpp.

References _generatedDemandVector, _mean, _stdDev, stdair::DEFAULT_RANDOM_SEED, and stdair::RandomGeneration::generateNormal().

void stdair::BookingClass::generateDemandSamples ( const int &  K,
const RandomSeed_T iSeed 
)

Generate demand samples for Monte-Carlo method with the given random seed.

Definition at line 73 of file BookingClass.cpp.

References _generatedDemandVector, _mean, _stdDev, and stdair::RandomGeneration::generateNormal().

Friends And Related Function Documentation

friend class FacBom
friend

Definition at line 25 of file BookingClass.hpp.

friend class FacBomManager
friend

Definition at line 26 of file BookingClass.hpp.

Member Data Documentation

Key_T stdair::BookingClass::_key
protected

Primary key (booking class code).

Definition at line 245 of file BookingClass.hpp.

Referenced by describeKey(), getClassCode(), and getKey().

BomAbstract* stdair::BookingClass::_parent
protected

Pointer on the parent class (SegmentCabin).

Definition at line 248 of file BookingClass.hpp.

Referenced by getParent().

HolderMap_T stdair::BookingClass::_holderMap
protected

Map holding the children (SegmentDate and LegDate objects).

Definition at line 251 of file BookingClass.hpp.

Referenced by getHolderMap().

SubclassCode_T stdair::BookingClass::_subclassCode
protected

Sub-class code.

Definition at line 254 of file BookingClass.hpp.

Referenced by getSubclassCode().

ProtectionLevel_T stdair::BookingClass::_cumulatedProtection
protected

Cumulated protection.

Definition at line 257 of file BookingClass.hpp.

Referenced by getCumulatedProtection(), and setCumulatedProtection().

ProtectionLevel_T stdair::BookingClass::_protection
protected

Protection.

Definition at line 260 of file BookingClass.hpp.

Referenced by getProtection(), and setProtection().

BookingLimit_T stdair::BookingClass::_cumulatedBookingLimit
protected

Cumulated booking limit.

Definition at line 263 of file BookingClass.hpp.

Referenced by getCumulatedBookingLimit(), and setCumulatedBookingLimit().

AuthorizationLevel_T stdair::BookingClass::_au
protected

Authorization level.

Definition at line 266 of file BookingClass.hpp.

Referenced by getAuthorizationLevel(), and setAuthorizationLevel().

NbOfSeats_T stdair::BookingClass::_nego
protected

Negotiated space.

Definition at line 269 of file BookingClass.hpp.

Referenced by getNegotiatedSpace().

OverbookingRate_T stdair::BookingClass::_noShowPercentage
protected

Overbooking rate.

Definition at line 272 of file BookingClass.hpp.

Referenced by getNoShowPercentage().

OverbookingRate_T stdair::BookingClass::_cancellationPercentage
protected

Cancellation rate.

Definition at line 275 of file BookingClass.hpp.

Referenced by getCancellationPercentage().

NbOfBookings_T stdair::BookingClass::_nbOfBookings
protected

Number of bookings.

Definition at line 278 of file BookingClass.hpp.

Referenced by cancel(), getNbOfBookings(), and sell().

NbOfBookings_T stdair::BookingClass::_groupNbOfBookings
protected

Number of group bookings.

Definition at line 281 of file BookingClass.hpp.

Referenced by getNbOfGroupBookings().

NbOfBookings_T stdair::BookingClass::_groupPendingNbOfBookings
protected

Number of pending group bookings.

Definition at line 284 of file BookingClass.hpp.

Referenced by getNbOfPendingGroupBookings().

NbOfBookings_T stdair::BookingClass::_staffNbOfBookings
protected

Number of staff bookings.

Definition at line 287 of file BookingClass.hpp.

Referenced by getNbOfStaffBookings().

NbOfBookings_T stdair::BookingClass::_wlNbOfBookings
protected

Number of wait-list bookings.

Definition at line 290 of file BookingClass.hpp.

Referenced by getNbOfWLBookings().

NbOfCancellations_T stdair::BookingClass::_nbOfCancellations
protected

Number of cancellations.

Definition at line 293 of file BookingClass.hpp.

Referenced by cancel(), and getNbOfCancellations().

NbOfBookings_T stdair::BookingClass::_etb
protected

Expected to board (ETB).

Definition at line 296 of file BookingClass.hpp.

Referenced by getETB().

Availability_T stdair::BookingClass::_netClassAvailability
protected

Net segment class availability.

Definition at line 299 of file BookingClass.hpp.

Referenced by getNetClassAvailability().

Availability_T stdair::BookingClass::_segmentAvailability
protected

Segment class availability.

Definition at line 302 of file BookingClass.hpp.

Referenced by getSegmentAvailability(), and setSegmentAvailability().

Availability_T stdair::BookingClass::_netRevenueAvailability
protected

Net revenue availability.

Definition at line 305 of file BookingClass.hpp.

Referenced by getNetRevenueAvailability().

Yield_T stdair::BookingClass::_yield
protected

Yield.

Definition at line 308 of file BookingClass.hpp.

Referenced by getYield(), and setYield().

MeanValue_T stdair::BookingClass::_mean
protected

Remaining demand distribution forecast.

Definition at line 311 of file BookingClass.hpp.

Referenced by generateDemandSamples(), getMean(), and setMean().

StdDevValue_T stdair::BookingClass::_stdDev
protected

Definition at line 312 of file BookingClass.hpp.

Referenced by generateDemandSamples(), getStdDev(), and setStdDev().

GeneratedDemandVector_T stdair::BookingClass::_generatedDemandVector
protected

Vector of number of demand samples drawn from the demand distribution.

Definition at line 315 of file BookingClass.hpp.

Referenced by generateDemandSamples(), and getGeneratedDemandVector().


The documentation for this class was generated from the following files: