SimCRS Logo  1.01.8
C++ Simulated Travel-Oriented Distribution System Library
Loading...
Searching...
No Matches
SIMCRS::FacSimcrsServiceContext Class Reference

#include <simcrs/factory/FacSimcrsServiceContext.hpp>

+ Inheritance diagram for SIMCRS::FacSimcrsServiceContext:

Public Types

typedef std::vector< ServiceAbstract * > ServicePool_T
 

Public Member Functions

 ~FacSimcrsServiceContext ()
 
SIMCRS_ServiceContextcreate (const std::string &iTravelDatabaseName)
 
void clean ()
 

Static Public Member Functions

static FacSimcrsServiceContextinstance ()
 

Protected Member Functions

 FacSimcrsServiceContext ()
 

Protected Attributes

ServicePool_T _pool
 

Detailed Description

Factory for Bucket.

Definition at line 18 of file FacSimcrsServiceContext.hpp.

Member Typedef Documentation

◆ ServicePool_T

Define the list (pool) of Service objects.

Definition at line 20 of file FacServiceAbstract.hpp.

Constructor & Destructor Documentation

◆ ~FacSimcrsServiceContext()

SIMCRS::FacSimcrsServiceContext::~FacSimcrsServiceContext ( )

Destructor.
The Destruction put the _instance to NULL in order to be clean for the next FacSimcrsServiceContext::instance()

Definition at line 16 of file FacSimcrsServiceContext.cpp.

◆ FacSimcrsServiceContext()

SIMCRS::FacSimcrsServiceContext::FacSimcrsServiceContext ( )
inlineprotected

Default Constructor.
This constructor is protected in order to ensure the singleton pattern.

Definition at line 42 of file FacSimcrsServiceContext.hpp.

Referenced by instance().

Member Function Documentation

◆ instance()

FacSimcrsServiceContext & SIMCRS::FacSimcrsServiceContext::instance ( )
static

Provide the unique instance.
The singleton is instantiated when first used

Returns
FacSimcrsServiceContext&

Definition at line 21 of file FacSimcrsServiceContext.cpp.

References FacSimcrsServiceContext(), SIMCRS::FacSupervisor::instance(), and SIMCRS::FacSupervisor::registerServiceFactory().

◆ create()

SIMCRS_ServiceContext & SIMCRS::FacSimcrsServiceContext::create ( const std::string &  iTravelDatabaseName)

Create a new SIMCRS_ServiceContext object.
This new object is added to the list of instantiated objects.

Returns
SIMCRS_ServiceContext& The newly created object.

Definition at line 33 of file FacSimcrsServiceContext.cpp.

References SIMCRS::FacServiceAbstract::_pool.

◆ clean()

void SIMCRS::FacServiceAbstract::clean ( )
inherited

Destroyed all the object instantiated by this factory.

Definition at line 18 of file FacServiceAbstract.cpp.

References SIMCRS::FacServiceAbstract::_pool.

Referenced by SIMCRS::FacServiceAbstract::~FacServiceAbstract().

Member Data Documentation

◆ _pool

ServicePool_T SIMCRS::FacServiceAbstract::_pool
protectedinherited

List of instantiated Business Objects

Definition at line 34 of file FacServiceAbstract.hpp.

Referenced by SIMCRS::FacServiceAbstract::clean(), and create().


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