CMS 3D CMS Logo

CSCChipSpeedCorrectionDBConditions.cc
Go to the documentation of this file.
1 #include <fstream>
2 #include <memory>
3 
7 
9  // the following line is needed to tell the framework what
10  // data is being produced
11  isForMC = iConfig.getUntrackedParameter<bool>("isForMC", true);
12  dataCorrFileName = iConfig.getUntrackedParameter<std::string>("dataCorrFileName", "empty.txt");
13  dataOffset = 170.;
14  // added by Zhen (changed since 1_2_0)
16  findingRecord<CSCDBChipSpeedCorrectionRcd>();
17  // now do what ever other initialization is needed
18 }
19 
21  // do anything here that needs to be done at desctruction time
22  // (e.g. close files, deallocate resources etc.)
23 }
24 
25 //
26 // member functions
27 //
28 
29 // ------------ method called to produce the data ------------
31  const CSCDBChipSpeedCorrectionRcd &iRecord) {
32  // need a new object so to not be deleted at exit
35 }
36 
38  const edm::IOVSyncValue &,
39  edm::ValidityInterval &oValidity) {
41 }
auto setWhatProduced(T *iThis, const es::Label &iLabel={})
Definition: ESProducer.h:124
T getUntrackedParameter(std::string const &, T const &) const
static const IOVSyncValue & endOfTime()
Definition: IOVSyncValue.cc:82
ReturnType produceDBChipSpeedCorrection(const CSCDBChipSpeedCorrectionRcd &)
std::pair< Time_t, Time_t > ValidityInterval
Definition: Time.h:19
static const IOVSyncValue & beginOfTime()
Definition: IOVSyncValue.cc:88
static CSCDBChipSpeedCorrection * prefillDBChipSpeedCorrection(bool isForMC, std::string dataCorrFileName, float dataOffse)
std::unique_ptr< CSCDBChipSpeedCorrection > ReturnType
CSCChipSpeedCorrectionDBConditions(const edm::ParameterSet &)
void setIntervalFor(const edm::eventsetup::EventSetupRecordKey &, const edm::IOVSyncValue &, edm::ValidityInterval &) override