Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-02-14 13:28:36

0001 #ifndef Integration_ThingProducer_h
0002 #define Integration_ThingProducer_h
0003 
0004 /** \class ThingProducer
0005  *
0006  * \version   1st Version Apr. 6, 2005  
0007 
0008  *
0009  ************************************************************/
0010 
0011 #include "FWCore/Framework/interface/Frameworkfwd.h"
0012 #include "FWCore/Framework/interface/global/EDProducer.h"
0013 #include "FWCore/Integration/test/ThingAlgorithm.h"
0014 #include "FWCore/Utilities/interface/EDPutToken.h"
0015 
0016 #include "DataFormats/TestObjects/interface/ThingCollection.h"
0017 
0018 namespace edmtest {
0019   class ThingProducer : public edm::global::EDProducer<edm::BeginRunProducer,
0020                                                        edm::EndRunProducer,
0021                                                        edm::EndLuminosityBlockProducer,
0022                                                        edm::BeginLuminosityBlockProducer> {
0023   public:
0024     explicit ThingProducer(edm::ParameterSet const& ps);
0025 
0026     ~ThingProducer() override;
0027 
0028     void produce(edm::StreamID, edm::Event& e, edm::EventSetup const& c) const override;
0029 
0030     void globalBeginRunProduce(edm::Run& r, edm::EventSetup const& c) const override;
0031 
0032     void globalEndRunProduce(edm::Run& r, edm::EventSetup const& c) const override;
0033 
0034     void globalBeginLuminosityBlockProduce(edm::LuminosityBlock& lb, edm::EventSetup const& c) const override;
0035 
0036     void globalEndLuminosityBlockProduce(edm::LuminosityBlock& lb, edm::EventSetup const& c) const override;
0037 
0038     static void fillDescriptions(edm::ConfigurationDescriptions& descriptions);
0039 
0040   private:
0041     ThingAlgorithm alg_;
0042     edm::EDPutTokenT<ThingCollection> evToken_;
0043     edm::EDPutTokenT<ThingCollection> brToken_;
0044     edm::EDPutTokenT<ThingCollection> erToken_;
0045     edm::EDPutTokenT<ThingCollection> blToken_;
0046     edm::EDPutTokenT<ThingCollection> elToken_;
0047     bool noPut_;
0048   };
0049 }  // namespace edmtest
0050 #endif