Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-11-09 23:31:50

0001 #ifndef ConditionDumperInEdm_H
0002 #define ConditionDumperInEdm_H
0003 // -*- C++ -*-
0004 //
0005 // Package:    ConditionDumperInEdm
0006 // Class:      ConditionDumperInEdm
0007 //
0008 /**\class ConditionDumperInEdm ConditionDumperInEdm.cc FWCore/ConditionDumperInEdm/src/ConditionDumperInEdm.cc
0009 
0010  Description: [one line class summary]
0011 
0012  Implementation:
0013      [Notes on implementation]
0014 */
0015 //
0016 // Original Author:  Jean-Roch Vlimant,40 3-A28,+41227671209,
0017 //         Created:  Thu Feb 11 19:46:28 CET 2010
0018 //
0019 //
0020 
0021 // system include files
0022 #include <memory>
0023 
0024 // user include files
0025 #include "FWCore/Framework/interface/Frameworkfwd.h"
0026 #include "FWCore/Framework/interface/one/EDProducer.h"
0027 
0028 #include "FWCore/Framework/interface/LuminosityBlock.h"
0029 #include "FWCore/Framework/interface/Run.h"
0030 #include "FWCore/Framework/interface/Event.h"
0031 #include "FWCore/Framework/interface/MakerMacros.h"
0032 
0033 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0034 
0035 #include "FWCore/Framework/interface/EventSetup.h"
0036 
0037 #include "FWCore/Utilities/interface/InputTag.h"
0038 
0039 #include "DataFormats/Common/interface/ConditionsInEdm.h"
0040 #include "DataFormats/L1GlobalTrigger/interface/L1GlobalTriggerEvmReadoutRecord.h"
0041 
0042 #include "CondFormats/DataRecord/interface/RunSummaryRcd.h"
0043 #include "CondFormats/RunInfo/interface/RunInfo.h"
0044 
0045 //
0046 // class declaration
0047 //
0048 
0049 class ConditionDumperInEdm : public edm::one::EDProducer<edm::RunCache<edm::ConditionsInRunBlock>,
0050                                                          edm::LuminosityBlockCache<edm::ConditionsInLumiBlock>,
0051                                                          edm::EndRunProducer,
0052                                                          edm::EndLuminosityBlockProducer> {
0053 public:
0054   explicit ConditionDumperInEdm(const edm::ParameterSet&);
0055   ~ConditionDumperInEdm() override;
0056 
0057 private:
0058   std::shared_ptr<edm::ConditionsInLumiBlock> globalBeginLuminosityBlock(edm::LuminosityBlock const&,
0059                                                                          edm::EventSetup const&) const final;
0060   void globalEndLuminosityBlock(edm::LuminosityBlock const&, edm::EventSetup const&) final {}
0061   void endLuminosityBlockProduce(edm::LuminosityBlock&, edm::EventSetup const&) final;
0062   std::shared_ptr<edm::ConditionsInRunBlock> globalBeginRun(edm::Run const&, const edm::EventSetup&) const final;
0063   void globalEndRun(edm::Run const&, const edm::EventSetup&) final {}
0064   void endRunProduce(edm::Run&, const edm::EventSetup&) final;
0065   void produce(edm::Event&, const edm::EventSetup&) final;
0066 
0067   // ----------member data ---------------------------
0068 
0069   const edm::InputTag gtEvmDigisLabel_;
0070 
0071   edm::ConditionsInEventBlock eventBlock_;
0072 
0073   const edm::EDGetTokenT<L1GlobalTriggerEvmReadoutRecord> gtEvmDigisLabelToken_;
0074   const edm::ESGetToken<RunInfo, RunInfoRcd> runInfoToken_;
0075   const edm::EDPutTokenT<edm::ConditionsInLumiBlock> lumiToken_;
0076   const edm::EDPutTokenT<edm::ConditionsInRunBlock> runToken_;
0077   const edm::EDPutTokenT<edm::ConditionsInEventBlock> eventToken_;
0078 };
0079 
0080 #endif