test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
WorkerRegistry.h
Go to the documentation of this file.
1 #ifndef Framework_WorkerRegistry_h
2 #define Framework_WorkerRegistry_h
3 
12 #include "boost/shared_ptr.hpp"
13 
14 #include <map>
15 #include <string>
16 
17 
18 namespace edm {
19 
20  class Worker;
21  class ActivityRegistry;
22  struct WorkerParams;
23  class ModuleRegistry;
24  class ParameterSet;
25  namespace maker {
26  class ModuleHolder;
27  }
28 
38 
39  public:
40 
41  explicit WorkerRegistry(boost::shared_ptr<ActivityRegistry> areg);
42  WorkerRegistry(boost::shared_ptr<ActivityRegistry> areg,
43  boost::shared_ptr<ModuleRegistry> iModReg);
45 
46  WorkerRegistry(WorkerRegistry const&) = delete; // Disallow copying and moving
47  WorkerRegistry& operator=(WorkerRegistry const&) = delete; // Disallow copying and moving
48 
50 
53  Worker* getWorker(WorkerParams const& p, std::string const& moduleLabel);
54  void clear();
55 
56  private:
58  typedef std::map<std::string, boost::shared_ptr<Worker> > WorkerMap;
59 
60  boost::shared_ptr<ModuleRegistry> modRegistry_;
61 
64  boost::shared_ptr<ActivityRegistry> actReg_;
65 
66  }; // WorkerRegistry
67 
68 
69 } // edm
70 
71 
72 #endif
WorkerRegistry(boost::shared_ptr< ActivityRegistry > areg)
boost::shared_ptr< ModuleRegistry > modRegistry_
boost::shared_ptr< ActivityRegistry > actReg_
WorkerRegistry & operator=(WorkerRegistry const &)=delete
WorkerMap m_workerMap
internal map of registered workers (owned).
areg
Definition: Schedule.cc:369
Worker * getWorker(WorkerParams const &p, std::string const &moduleLabel)
Retrieve the particular instance of the worker.
The Registry of all workers that where requested Holds all instances of workers. In this implementati...
std::map< std::string, boost::shared_ptr< Worker > > WorkerMap
the container of workers