CMS 3D CMS Logo

ModuleRegistry.h
Go to the documentation of this file.
1 #ifndef FWCore_Framework_ModuleRegistry_h
2 #define FWCore_Framework_ModuleRegistry_h
3 // -*- C++ -*-
4 //
5 // Package: FWCore/Framework
6 // Class : ModuleRegistry
7 //
16 //
17 // Original Author: Chris Jones
18 // Created: Fri, 23 Aug 2013 16:21:10 GMT
19 //
20 
21 // system include files
22 #include <map>
23 #include <memory>
24 #include <string>
25 
26 // user include files
29 
30 // forward declarations
31 namespace edm {
32  class ParameterSet;
33  struct MakeModuleParams;
34  class ModuleDescription;
35  class PreallocationConfiguration;
36  namespace maker {
37  class ModuleHolder;
38  }
39 
41  public:
42  std::shared_ptr<maker::ModuleHolder> getModule(MakeModuleParams const& p,
43  std::string const& moduleLabel,
44  signalslot::Signal<void(ModuleDescription const&)>& iPre,
45  signalslot::Signal<void(ModuleDescription const&)>& iPost);
46 
47  maker::ModuleHolder* replaceModule(std::string const& iModuleLabel,
48  edm::ParameterSet const& iPSet,
50 
51  template <typename F>
52  void forAllModuleHolders(F iFunc) {
53  for (auto& labelMod : labelToModule_) {
54  maker::ModuleHolder* t = labelMod.second.get();
55  iFunc(t);
56  }
57  }
58 
59  private:
60  std::map<std::string, edm::propagate_const<std::shared_ptr<maker::ModuleHolder>>> labelToModule_;
61  };
62 } // namespace edm
63 
64 #endif
std::map< std::string, edm::propagate_const< std::shared_ptr< maker::ModuleHolder > > > labelToModule_
void forAllModuleHolders(F iFunc)
HLT enums.
static uInt32 F(BLOWFISH_CTX *ctx, uInt32 x)
Definition: blowfish.cc:163