StdAir Logo  1.00.5
C++ Standard Airline IT Object Library
stdair::Bucket Class Reference

Class representing the actual attributes for an airline booking class. More...

#include <stdair/bom/Bucket.hpp>

+ Inheritance diagram for stdair::Bucket:

Public Types

typedef BucketKey Key_T
 

Public Member Functions

const Key_TgetKey () const
 
BomAbstract *const getParent () const
 
const HolderMap_TgetHolderMap () const
 
const SeatIndex_TgetSeatIndex () const
 
const Yield_TgetYieldRangeUpperValue () const
 
const CabinCapacity_TgetAvailability () const
 
const NbOfSeats_TgetSoldSeats () const
 
void setYieldRangeUpperValue (const Yield_T &iYield)
 
void setAvailability (const CabinCapacity_T &iAvl)
 
void setSoldSeats (const NbOfSeats_T &iSoldSeats)
 
void toStream (std::ostream &ioOut) const
 
void fromStream (std::istream &ioIn)
 
std::string toString () const
 
const std::string describeKey () const
 
template<class Archive >
void serialize (Archive &ar, const unsigned int iFileVersion)
 

Protected Member Functions

 Bucket (const Key_T &)
 
virtual ~Bucket ()
 

Protected Attributes

Key_T _key
 
BomAbstract_parent
 
HolderMap_T _holderMap
 
Yield_T _yieldRangeUpperValue
 
CabinCapacity_T _availability
 
NbOfSeats_T _soldSeats
 

Friends

template<typename BOM >
class FacBom
 
template<typename BOM >
class FacCloneBom
 
class FacBomManager
 
class boost::serialization::access
 

Detailed Description

Class representing the actual attributes for an airline booking class.

Definition at line 29 of file Bucket.hpp.

Member Typedef Documentation

◆ Key_T

Definition allowing to retrieve the associated BOM key type.

Definition at line 40 of file Bucket.hpp.

Constructor & Destructor Documentation

◆ Bucket()

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

Default constructor.

Definition at line 34 of file Bucket.cpp.

◆ ~Bucket()

stdair::Bucket::~Bucket ( )
protectedvirtual

Destructor.

Definition at line 38 of file Bucket.cpp.

Member Function Documentation

◆ getKey()

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

Get the primary key of the bucket.

Definition at line 47 of file Bucket.hpp.

◆ getParent()

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

Get the parent object.

Definition at line 54 of file Bucket.hpp.

◆ getHolderMap()

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

Get the map of children holders.

Definition at line 59 of file Bucket.hpp.

◆ getSeatIndex()

const SeatIndex_T& stdair::Bucket::getSeatIndex ( ) const
inline

Get the seat index (part of the primary key).

Definition at line 64 of file Bucket.hpp.

Referenced by stdair::BomJSONExport::jsonExportFlightDateObjects().

◆ getYieldRangeUpperValue()

const Yield_T& stdair::Bucket::getYieldRangeUpperValue ( ) const
inline

Get the upper yield range.

Definition at line 69 of file Bucket.hpp.

Referenced by stdair::BomJSONExport::jsonExportFlightDateObjects().

◆ getAvailability()

const CabinCapacity_T& stdair::Bucket::getAvailability ( ) const
inline

Get the availability.

Definition at line 74 of file Bucket.hpp.

Referenced by stdair::BomJSONExport::jsonExportFlightDateObjects().

◆ getSoldSeats()

const NbOfSeats_T& stdair::Bucket::getSoldSeats ( ) const
inline

Get the number of seats already sold.

Definition at line 79 of file Bucket.hpp.

Referenced by stdair::BomJSONExport::jsonExportFlightDateObjects().

◆ setYieldRangeUpperValue()

void stdair::Bucket::setYieldRangeUpperValue ( const Yield_T iYield)
inline

Set the upper yield range.

Definition at line 86 of file Bucket.hpp.

◆ setAvailability()

void stdair::Bucket::setAvailability ( const CabinCapacity_T iAvl)
inline

Set the availability.

Definition at line 91 of file Bucket.hpp.

◆ setSoldSeats()

void stdair::Bucket::setSoldSeats ( const NbOfSeats_T iSoldSeats)
inline

Set the number of seats already sold.

Definition at line 96 of file Bucket.hpp.

◆ toStream()

void stdair::Bucket::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 108 of file Bucket.hpp.

◆ fromStream()

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

Read a Business Object from an input stream.

Parameters
istream&the input stream.

Implements stdair::BomAbstract.

Definition at line 117 of file Bucket.hpp.

◆ toString()

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

Get the serialised version of the Business Object.

Implements stdair::BomAbstract.

Definition at line 42 of file Bucket.cpp.

References describeKey().

◆ describeKey()

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

Get a string describing the key.

Definition at line 128 of file Bucket.hpp.

Referenced by toString().

◆ serialize()

template<class Archive >
void stdair::Bucket::serialize ( Archive &  ar,
const unsigned int  iFileVersion 
)

Serialisation.

Definition at line 64 of file Bucket.cpp.

References _key.

Friends And Related Function Documentation

◆ FacBom

template<typename BOM >
friend class FacBom
friend

Definition at line 30 of file Bucket.hpp.

◆ FacCloneBom

template<typename BOM >
friend class FacCloneBom
friend

Definition at line 31 of file Bucket.hpp.

◆ FacBomManager

friend class FacBomManager
friend

Definition at line 32 of file Bucket.hpp.

◆ boost::serialization::access

friend class boost::serialization::access
friend

Definition at line 33 of file Bucket.hpp.

Member Data Documentation

◆ _key

Key_T stdair::Bucket::_key
protected

Primary key (upper yield range).

Definition at line 179 of file Bucket.hpp.

Referenced by serialize().

◆ _parent

BomAbstract* stdair::Bucket::_parent
protected

Pointer on the parent class (LegCabin).

Definition at line 184 of file Bucket.hpp.

◆ _holderMap

HolderMap_T stdair::Bucket::_holderMap
protected

Map holding the children (empty for now).

Definition at line 189 of file Bucket.hpp.

◆ _yieldRangeUpperValue

Yield_T stdair::Bucket::_yieldRangeUpperValue
protected

Upper yield range.

Definition at line 197 of file Bucket.hpp.

◆ _availability

CabinCapacity_T stdair::Bucket::_availability
protected

Availability.

Definition at line 202 of file Bucket.hpp.

◆ _soldSeats

NbOfSeats_T stdair::Bucket::_soldSeats
protected

Number of seats already sold.

Definition at line 207 of file Bucket.hpp.


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