CalibMuon
CSCCalibration
plugins
CSCCrosstalkDBConditions.cc
Go to the documentation of this file.
1
#include <fstream>
2
#include <memory>
3
4
#include "
CalibMuon/CSCCalibration/interface/CSCCrosstalkDBConditions.h
"
5
#include "
CondFormats/CSCObjects/interface/CSCDBCrosstalk.h
"
6
#include "
CondFormats/DataRecord/interface/CSCDBCrosstalkRcd.h
"
7
8
CSCCrosstalkDBConditions::CSCCrosstalkDBConditions
(
const
edm::ParameterSet
&iConfig) {
9
// the following line is needed to tell the framework what
10
// data is being produced
11
// added by Zhen (changed since 1_2_0)
12
setWhatProduced
(
this
, &
CSCCrosstalkDBConditions::produceDBCrosstalk
);
13
findingRecord<CSCDBCrosstalkRcd>();
14
// now do what ever other initialization is needed
15
}
16
17
CSCCrosstalkDBConditions::~CSCCrosstalkDBConditions
() {
18
// do anything here that needs to be done at desctruction time
19
// (e.g. close files, deallocate resources etc.)
20
}
21
22
//
23
// member functions
24
//
25
26
// ------------ method called to produce the data ------------
27
CSCCrosstalkDBConditions::ReturnType
CSCCrosstalkDBConditions::produceDBCrosstalk
(
const
CSCDBCrosstalkRcd
&iRecord) {
28
// need a new object so to not be deleted at exit
29
return
CSCCrosstalkDBConditions::ReturnType
(
prefillDBCrosstalk
());
30
}
31
32
void
CSCCrosstalkDBConditions::setIntervalFor
(
const
edm::eventsetup::EventSetupRecordKey
&,
33
const
edm::IOVSyncValue
&,
34
edm::ValidityInterval
&oValidity) {
35
oValidity =
edm::ValidityInterval
(
edm::IOVSyncValue::beginOfTime
(),
edm::IOVSyncValue::endOfTime
());
36
}
CSCCrosstalkDBConditions.h
edm::ESProducer::setWhatProduced
auto setWhatProduced(T *iThis, const es::Label &iLabel={})
Definition:
ESProducer.h:163
edm::ValidityInterval
Definition:
ValidityInterval.h:28
CSCDBCrosstalk.h
CSCCrosstalkDBConditions::CSCCrosstalkDBConditions
CSCCrosstalkDBConditions(const edm::ParameterSet &)
Definition:
CSCCrosstalkDBConditions.cc:8
CSCDBCrosstalkRcd
Definition:
CSCDBCrosstalkRcd.h:5
edm::eventsetup::EventSetupRecordKey
Definition:
EventSetupRecordKey.h:30
CSCCrosstalkDBConditions::prefillDBCrosstalk
static CSCDBCrosstalk * prefillDBCrosstalk()
Definition:
CSCCrosstalkDBConditions.h:43
edm::IOVSyncValue
Definition:
IOVSyncValue.h:31
CSCCrosstalkDBConditions::ReturnType
std::unique_ptr< CSCDBCrosstalk > ReturnType
Definition:
CSCCrosstalkDBConditions.h:27
edm::ParameterSet
Definition:
ParameterSet.h:47
edm::IOVSyncValue::endOfTime
static const IOVSyncValue & endOfTime()
Definition:
IOVSyncValue.cc:82
CSCDBCrosstalkRcd.h
cond::ValidityInterval
std::pair< Time_t, Time_t > ValidityInterval
Definition:
Time.h:17
edm::IOVSyncValue::beginOfTime
static const IOVSyncValue & beginOfTime()
Definition:
IOVSyncValue.cc:88
CSCCrosstalkDBConditions::produceDBCrosstalk
ReturnType produceDBCrosstalk(const CSCDBCrosstalkRcd &)
Definition:
CSCCrosstalkDBConditions.cc:27
CSCCrosstalkDBConditions::~CSCCrosstalkDBConditions
~CSCCrosstalkDBConditions() override
Definition:
CSCCrosstalkDBConditions.cc:17
CSCCrosstalkDBConditions::setIntervalFor
void setIntervalFor(const edm::eventsetup::EventSetupRecordKey &, const edm::IOVSyncValue &, edm::ValidityInterval &) override
Definition:
CSCCrosstalkDBConditions.cc:32
Generated for CMSSW Reference Manual by
1.8.16