Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 13:26:08

0001 #ifndef EventFilter_L1TRawToDigi_UnpackerFactory_h
0002 #define EventFilter_L1TRawToDigi_UnpackerFactory_h
0003 
0004 #include "FWCore/PluginManager/interface/PluginFactory.h"
0005 
0006 #include "EventFilter/L1TRawToDigi/interface/Unpacker.h"
0007 
0008 namespace l1t {
0009   typedef Unpacker*(unpack_fct)();
0010   typedef edmplugin::PluginFactory<unpack_fct> UnpackerFactoryT;
0011 
0012   class UnpackerFactory {
0013   public:
0014     inline static const UnpackerFactory* get() { return &instance_; };
0015     std::shared_ptr<Unpacker> make(const std::string&) const;
0016 
0017   private:
0018     UnpackerFactory(){};
0019     static const UnpackerFactory instance_;
0020   };
0021 }  // namespace l1t
0022 
0023 #define DEFINE_L1T_UNPACKER(type) DEFINE_EDM_PLUGIN(l1t::UnpackerFactoryT, type, #type)
0024 
0025 #endif