Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-05-18 09:15:23

0001 #ifndef ProducePFCalibrationObject_H
0002 #define ProducePFCalibrationObject_H
0003 
0004 /** \class ProducePFCalibrationObject
0005  *  
0006  *  
0007  *  This is used by ProducePFCalibration.py config to 
0008  *  generate payload for offline and HLT PF hadron calibration.
0009  *  
0010  *  \Original author G. Cerminara - CERN
0011  */
0012 
0013 #include "FWCore/Framework/interface/EDAnalyzer.h"
0014 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0015 #include "CondFormats/PhysicsToolsObjects/interface/PerformancePayloadFromTFormula.h"
0016 #include "CondFormats/DataRecord/interface/PFCalibrationRcd.h"
0017 
0018 #include <vector>
0019 #include <string>
0020 
0021 class ProducePFCalibrationObject : public edm::EDAnalyzer {
0022 public:
0023   /// Constructor
0024   ProducePFCalibrationObject(const edm::ParameterSet&);
0025 
0026   /// Destructor
0027   virtual ~ProducePFCalibrationObject();
0028 
0029   // Operations
0030   //   virtual void beginJob();
0031   virtual void beginRun(const edm::Run& run, const edm::EventSetup& eSetup);
0032 
0033   virtual void analyze(const edm::Event&, const edm::EventSetup&) {}
0034   virtual void endJob() {}
0035 
0036 protected:
0037 private:
0038   bool read;
0039   bool write;
0040 
0041   std::vector<edm::ParameterSet> fToWrite;
0042   std::vector<std::string> fToRead;
0043 
0044   const edm::ESGetToken<PerformancePayload, PFCalibrationRcd> perfToken;
0045 };
0046 #endif