Gaudi Framework, version v23r9

Home   Generated: Thu Jul 18 2013
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
ApplicationMgr.h
Go to the documentation of this file.
1 // $Header: /tmp/svngaudi/tmp.jEpFh25751/Gaudi/GaudiSvc/src/ApplicationMgr/ApplicationMgr.h,v 1.34 2008/11/10 15:29:09 marcocle Exp $ //
2 #ifndef GAUDI_APPLICATIONMGR_H
3 #define GAUDI_APPLICATIONMGR_H
4 
5 #include "GaudiKernel/Kernel.h"
11 #include "GaudiKernel/IAlgorithm.h"
14 #include "GaudiKernel/Service.h"
17 
18 // STL include files
19 #include <list>
20 #include <vector>
21 
22 // Forward declarations
23 class ISvcLocator;
24 class ServiceManager;
25 class AlgorithmManager;
26 class DLLClassManager;
27 
28 class IMessageSvc;
29 class IIncidentSvc;
30 class IRunable;
31 class IDataManagerSvc;
32 class IConversionSvc;
33 class IJobOptionsSvc;
34 
47 class ApplicationMgr : public CommonMessaging<implements4<IAppMgrUI,
48  IEventProcessor,
49  IService,
50  IStateful> > {
53  IService,
55 public:
59 
60 public:
61 
62  // default creator
64  // virtual destructor
65  virtual ~ApplicationMgr();
66 
67  // implementation of IInterface::queryInterface
68  virtual StatusCode queryInterface(const InterfaceID& iid, void** pinterface);
69 
70  // implementation of IAppMgrUI::run
71  virtual StatusCode run();
72  // implementation of IAppMgrUI::configure
73  virtual StatusCode configure();
74  // implementation of IAppMgrUI::terminate
75  virtual StatusCode terminate();
76  // implementation of IAppMgrUI::initialize
77  virtual StatusCode initialize();
78  // implementation of IAppMgrUI::start
79  virtual StatusCode start();
80  // implementation of IAppMgrUI::stop
81  virtual StatusCode stop();
82  // implementation of IAppMgrUI::finalize
83  virtual StatusCode finalize();
84  // implementation of IAppMgrUI::nextEvent
85  virtual StatusCode nextEvent(int maxevt);
86  // implementation of IAppMgrUI::name
87  virtual const std::string& name() const;
89  virtual StatusCode executeEvent(void* par);
91  virtual StatusCode executeRun(int evtmax);
93  virtual StatusCode stopRun();
94 
95  // implementation of IStateful::state
96  virtual Gaudi::StateMachine::State FSMState() const;
97  // implementation of IStateful::targetState
99  // implementation of IStateful::reinitialize
100  virtual StatusCode reinitialize();
101  // implementation of IStateful::reinitialize
102  virtual StatusCode restart();
103  // implementation of IService::sysItinitilaize
105  // implementation of IService::sysStart
107  // implementation of IService::sysStop
108  virtual StatusCode sysStop() { return StatusCode::SUCCESS; }
109  // implementation of IService::sysFinalize
111  // implementation of IService::sysReinitialize
113  // implementation of IService::sysRestart
115 
116  // SI Go Handler
117  void SIGoHandler ( Property& theProp );
118  // SI Exit handler
119  void SIExitHandler ( Property& theProp );
120 
122 
123  void evtLoopPropertyHandler ( Property& theProp );
127  void extSvcNameListHandler ( Property& theProp );
129  void multiThreadSvcNameListHandler( Property& theProp );
131  void dllNameListHandler ( Property& theProp );
132  void reflexDebugPropertyHandler ( Property& theProp );
133  void initLoopCheckHndlr ( Property& );
135 
136  template <class I>
138  return m_managers[I::interfaceID().id()];
139  }
140 
142  // Cache the casted pointer to ISvcManager
143  if (!m_svcManager) {
144  m_svcManager = getManager<IService>();
145  }
146  return m_svcManager;
147  }
148 
150  // Cache the casted pointer to IAlgManager
151  if (!m_algManager) {
152  m_algManager = getManager<IAlgorithm>();
153  }
154  return m_algManager;
155  }
156 
159  return m_svcLocator;
160  }
161 
162 protected:
165  const std::string& type);
167  StatusCode addMultiSvc(const Gaudi::Utils::TypeNameString &typeName,
168  int prio);
169 
170  // implementation of IService::setServiceManager
172 
175 
180  StatusCode GoToState(Gaudi::StateMachine::State state, bool ignoreFailures = false);
181 
191 
194 
197 
198 
199  // data members
202 
210 
211 
214 
218 
222 
228 
229  //
230  // The public ApplicationMgr properties
231  //
232 
233  int m_evtMax;
236 
240 
252  bool m_codeCheck;
254 
256 
261 
263 
266 
270 
274 
275  // Flag to activate the printout of properties
277 
280 
281 private:
283 };
284 #endif // GAUDI_APPLICATIONMGR_H

Generated at Thu Jul 18 2013 12:18:02 for Gaudi Framework, version v23r9 by Doxygen version 1.8.2 written by Dimitri van Heesch, © 1997-2004