StdAir Logo  0.45.1
C++ Standard Airline IT Object Library
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
FacSupervisor.hpp
Go to the documentation of this file.
00001 #ifndef __STDAIR_SVC_FACSUPERVISOR_HPP
00002 #define __STDAIR_SVC_FACSUPERVISOR_HPP
00003 
00004 // //////////////////////////////////////////////////////////////////////
00005 // Import section
00006 // //////////////////////////////////////////////////////////////////////
00007 // STL
00008 #include <iosfwd>
00009 #include <list>
00010 
00011 namespace stdair {
00012 
00014   class FacAbstract;
00015   class FacServiceAbstract;
00016 
00020   class FacSupervisor {
00021   public:
00025     typedef std::list<FacAbstract*> BomFactoryPool_T;
00026     typedef std::list<FacServiceAbstract*> ServiceFactoryPool_T;
00027 
00034     static FacSupervisor& instance();
00035 
00043     void registerBomFactory (FacAbstract*);
00044 
00052     void registerServiceFactory (FacServiceAbstract*);
00053 
00060     void cleanBomLayer();
00061 
00068     void cleanServiceLayer();
00069 
00073     static void cleanLoggerService();
00074 
00078     static void cleanDBSessionManager();
00079 
00085     static void cleanAll();
00086 
00093     ~FacSupervisor();
00094 
00095 
00096   protected:
00102     FacSupervisor() {}
00103     FacSupervisor (const FacSupervisor&) {}
00104 
00105   private:
00109     static FacSupervisor* _instance;
00110 
00114     BomFactoryPool_T _bomPool;
00115 
00119     ServiceFactoryPool_T _svcPool;
00120   };
00121 }  
00122 #endif // __STDAIR_SVC_FACSUPERVISOR_HPP