CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
EcalDBCopy Class Reference

#include <EcalDBCopy.h>

Inheritance diagram for EcalDBCopy:
edm::one::EDAnalyzer<> edm::one::EDAnalyzerBase edm::EDConsumerBase

Public Member Functions

void analyze (const edm::Event &evt, const edm::EventSetup &evtSetup) override
 
 EcalDBCopy (const edm::ParameterSet &iConfig)
 
 ~EcalDBCopy () override
 
- Public Member Functions inherited from edm::one::EDAnalyzer<>
 EDAnalyzer ()=default
 
 EDAnalyzer (const EDAnalyzer &)=delete
 
SerialTaskQueueglobalLuminosityBlocksQueue () final
 
SerialTaskQueueglobalRunsQueue () final
 
const EDAnalyzeroperator= (const EDAnalyzer &)=delete
 
bool wantsGlobalLuminosityBlocks () const final
 
bool wantsGlobalRuns () const final
 
bool wantsInputProcessBlocks () const final
 
bool wantsProcessBlocks () const final
 
- Public Member Functions inherited from edm::one::EDAnalyzerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
 EDAnalyzerBase ()
 
ModuleDescription const & moduleDescription () const
 
bool wantsStreamLuminosityBlocks () const
 
bool wantsStreamRuns () const
 
 ~EDAnalyzerBase () override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
 EDConsumerBase (EDConsumerBase &&)=default
 
ESResolverIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESResolverIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex > const & esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector< ProductResolverIndexAndSkipBit > const & itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::array< std::vector< ModuleDescription const *> *, NumBranchTypes > &modulesAll, std::vector< ModuleProcessName > &modulesInPreviousProcesses, ProductRegistry const &preg, std::map< std::string, ModuleDescription const *> const &labelsToDesc, std::string const &processName) const
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
void selectInputProcessBlocks (ProductRegistry const &productRegistry, ProcessBlockHelperBase const &processBlockHelperBase)
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProductResolverIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Private Member Functions

void copyToDB (const edm::EventSetup &evtSetup, const std::string &container)
 
bool shouldCopy (const edm::EventSetup &evtSetup, const std::string &container)
 

Private Attributes

edm::ESGetToken< Alignments, EBAlignmentRcdebAlignmentToken_
 
edm::ESGetToken< EcalADCToGeVConstant, EcalADCToGeVConstantRcdecalADCtoGeVToken_
 
edm::ESGetToken< EcalChannelStatus, EcalChannelStatusRcdecalChannelStatusToken_
 
edm::ESGetToken< EcalClusterCrackCorrParameters, EcalClusterCrackCorrParametersRcdecalClusterCrackCorrParametersToken_
 
edm::ESGetToken< EcalClusterEnergyCorrectionObjectSpecificParameters, EcalClusterEnergyCorrectionObjectSpecificParametersRcdecalClusterEnergyCorrectionObjectSpecificParametersToken_
 
edm::ESGetToken< EcalClusterEnergyCorrectionParameters, EcalClusterEnergyCorrectionParametersRcdecalClusterEnergyCorrectionParametersToken_
 
edm::ESGetToken< EcalClusterEnergyUncertaintyParameters, EcalClusterEnergyUncertaintyParametersRcdecalClusterEnergyUncertaintyParametersToken_
 
edm::ESGetToken< EcalClusterLocalContCorrParameters, EcalClusterLocalContCorrParametersRcdecalClusterLocalContCorrParametersToken_
 
edm::ESGetToken< EcalDAQTowerStatus, EcalDAQTowerStatusRcdecalDAQTowerStatusToken_
 
edm::ESGetToken< EcalDCSTowerStatus, EcalDCSTowerStatusRcdecalDCSTowerStatusToken_
 
edm::ESGetToken< EcalDQMChannelStatus, EcalDQMChannelStatusRcdecalDQMChannelStatusToken_
 
edm::ESGetToken< EcalDQMTowerStatus, EcalDQMTowerStatusRcdecalDQMTowerStatusToken_
 
edm::ESGetToken< EcalGainRatios, EcalGainRatiosRcdecalGainRatiosToken_
 
edm::ESGetToken< EcalIntercalibConstantsMC, EcalIntercalibConstantsMCRcdecalIntercalibConstantsMCToken_
 
edm::ESGetToken< EcalIntercalibConstants, EcalIntercalibConstantsRcdecalIntercalibConstantsToken_
 
edm::ESGetToken< EcalIntercalibErrors, EcalIntercalibErrorsRcdecalIntercalibErrorsToken_
 
edm::ESGetToken< EcalLaserAlphas, EcalLaserAlphasRcdecalLaserAlphasToken_
 
edm::ESGetToken< EcalLaserAPDPNRatiosRef, EcalLaserAPDPNRatiosRefRcdecalLaserAPDPNRatiosRefToken_
 
edm::ESGetToken< EcalLaserAPDPNRatios, EcalLaserAPDPNRatiosRcdecalLaserAPDPNRatiosToken_
 
edm::ESGetToken< EcalLinearCorrections, EcalLinearCorrectionsRcdecalLinearCorrectionsToken_
 
edm::ESGetToken< EcalPedestals, EcalPedestalsRcdecalPedestalToken_
 
edm::ESGetToken< EcalPFRecHitThresholds, EcalPFRecHitThresholdsRcdecalPFRecHitThresholdsToken_
 
edm::ESGetToken< EcalSampleMask, EcalSampleMaskRcdecalSampleMaskToken_
 
edm::ESGetToken< EcalSamplesCorrelation, EcalSamplesCorrelationRcdecalSamplesCorrelationToken_
 
edm::ESGetToken< EcalSimComponentShape, EcalSimComponentShapeRcdecalSimComponentShapeToken_
 
edm::ESGetToken< EcalSimPulseShape, EcalSimPulseShapeRcdecalSimPulseShapeToken_
 
edm::ESGetToken< EcalTBWeights, EcalTBWeightsRcdecalTBWeightsToken_
 
edm::ESGetToken< EcalTimeBiasCorrections, EcalTimeBiasCorrectionsRcdecalTimeBiasCorrectionsToken_
 
edm::ESGetToken< EcalTimeCalibConstants, EcalTimeCalibConstantsRcdecalTimeCalibToken_
 
edm::ESGetToken< EcalTimeOffsetConstant, EcalTimeOffsetConstantRcdecalTimeOffsetConstantToken_
 
edm::ESGetToken< EcalTPGCrystalStatus, EcalTPGCrystalStatusRcdecalTPGCrystalStatusToken_
 
edm::ESGetToken< EcalTPGTowerStatus, EcalTPGTowerStatusRcdecalTPGTowerStatusToken_
 
edm::ESGetToken< EcalWeightXtalGroups, EcalWeightXtalGroupsRcdecalWeightXtalGroupsToken_
 
edm::ESGetToken< Alignments, EEAlignmentRcdeeAlignmentToken_
 
edm::ESGetToken< Alignments, ESAlignmentRcdesAlignmentToken_
 
std::map< std::string, unsigned long long > m_cacheIDs
 
std::map< std::string, std::string > m_records
 
std::string m_timetype
 

Additional Inherited Members

- Public Types inherited from edm::one::EDAnalyzerBase
typedef EDAnalyzerBase ModuleType
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::one::EDAnalyzerBase
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 
- Protected Member Functions inherited from edm::EDConsumerBase
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< Bconsumes (edm::InputTag tag) noexcept
 
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
constexpr auto esConsumes ()
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag)
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
void resetItemsToGetFrom (BranchType iType)
 

Detailed Description

Definition at line 88 of file EcalDBCopy.h.

Constructor & Destructor Documentation

◆ EcalDBCopy()

EcalDBCopy::EcalDBCopy ( const edm::ParameterSet iConfig)
explicit

Definition at line 61 of file EcalDBCopy.cc.

References edm::ParameterSet::getParameter(), m_cacheIDs, m_records, AlCaHarvesting_cff::record, and AlCaHLTBitMon_QueryRunRegistry::string.

62  : m_timetype(iConfig.getParameter<std::string>("timetype")),
63  m_cacheIDs(),
64  m_records(),
100  std::string container;
102  typedef std::vector<edm::ParameterSet> Parameters;
103  Parameters toCopy = iConfig.getParameter<Parameters>("toCopy");
104  for (auto& iparam : toCopy) {
105  container = iparam.getParameter<std::string>("container");
106  record = iparam.getParameter<std::string>("record");
107  m_cacheIDs.emplace(container, 0);
108  m_records.emplace(container, record);
109  }
110 }
edm::ESGetToken< EcalDQMTowerStatus, EcalDQMTowerStatusRcd > ecalDQMTowerStatusToken_
Definition: EcalDBCopy.h:107
std::string m_timetype
Definition: EcalDBCopy.h:99
edm::ESGetToken< EcalIntercalibConstants, EcalIntercalibConstantsRcd > ecalIntercalibConstantsToken_
Definition: EcalDBCopy.h:112
T getParameter(std::string const &) const
Definition: ParameterSet.h:307
edm::ESGetToken< EcalTBWeights, EcalTBWeightsRcd > ecalTBWeightsToken_
Definition: EcalDBCopy.h:118
edm::ESGetToken< EcalLaserAlphas, EcalLaserAlphasRcd > ecalLaserAlphasToken_
Definition: EcalDBCopy.h:119
std::map< std::string, std::string > m_records
Definition: EcalDBCopy.h:101
edm::ESGetToken< EcalIntercalibErrors, EcalIntercalibErrorsRcd > ecalIntercalibErrorsToken_
Definition: EcalDBCopy.h:115
edm::ESGetToken< Alignments, EBAlignmentRcd > ebAlignmentToken_
Definition: EcalDBCopy.h:134
edm::ESGetToken< EcalSamplesCorrelation, EcalSamplesCorrelationRcd > ecalSamplesCorrelationToken_
Definition: EcalDBCopy.h:142
edm::ESGetToken< EcalWeightXtalGroups, EcalWeightXtalGroupsRcd > ecalWeightXtalGroupsToken_
Definition: EcalDBCopy.h:117
edm::ESGetToken< EcalTimeBiasCorrections, EcalTimeBiasCorrectionsRcd > ecalTimeBiasCorrectionsToken_
Definition: EcalDBCopy.h:141
edm::ESGetToken< EcalDCSTowerStatus, EcalDCSTowerStatusRcd > ecalDCSTowerStatusToken_
Definition: EcalDBCopy.h:108
edm::ESGetToken< EcalPFRecHitThresholds, EcalPFRecHitThresholdsRcd > ecalPFRecHitThresholdsToken_
Definition: EcalDBCopy.h:124
edm::ESGetToken< EcalGainRatios, EcalGainRatiosRcd > ecalGainRatiosToken_
Definition: EcalDBCopy.h:116
edm::ESGetToken< EcalClusterLocalContCorrParameters, EcalClusterLocalContCorrParametersRcd > ecalClusterLocalContCorrParametersToken_
Definition: EcalDBCopy.h:133
edm::ESGetToken< EcalSimPulseShape, EcalSimPulseShapeRcd > ecalSimPulseShapeToken_
Definition: EcalDBCopy.h:140
edm::ESGetToken< EcalTimeCalibConstants, EcalTimeCalibConstantsRcd > ecalTimeCalibToken_
Definition: EcalDBCopy.h:104
edm::ESGetToken< EcalClusterEnergyUncertaintyParameters, EcalClusterEnergyUncertaintyParametersRcd > ecalClusterEnergyUncertaintyParametersToken_
Definition: EcalDBCopy.h:126
edm::ESGetToken< EcalSimComponentShape, EcalSimComponentShapeRcd > ecalSimComponentShapeToken_
Definition: EcalDBCopy.h:139
edm::ESGetToken< EcalLinearCorrections, EcalLinearCorrectionsRcd > ecalLinearCorrectionsToken_
Definition: EcalDBCopy.h:113
edm::ESGetToken< EcalClusterEnergyCorrectionParameters, EcalClusterEnergyCorrectionParametersRcd > ecalClusterEnergyCorrectionParametersToken_
Definition: EcalDBCopy.h:128
edm::ESGetToken< EcalClusterEnergyCorrectionObjectSpecificParameters, EcalClusterEnergyCorrectionObjectSpecificParametersRcd > ecalClusterEnergyCorrectionObjectSpecificParametersToken_
Definition: EcalDBCopy.h:131
edm::ESGetToken< Alignments, ESAlignmentRcd > esAlignmentToken_
Definition: EcalDBCopy.h:136
edm::ESGetToken< EcalPedestals, EcalPedestalsRcd > ecalPedestalToken_
Definition: EcalDBCopy.h:102
edm::ESGetToken< Alignments, EEAlignmentRcd > eeAlignmentToken_
Definition: EcalDBCopy.h:135
edm::ESGetToken< EcalTPGTowerStatus, EcalTPGTowerStatusRcd > ecalTPGTowerStatusToken_
Definition: EcalDBCopy.h:111
edm::ESGetToken< EcalDAQTowerStatus, EcalDAQTowerStatusRcd > ecalDAQTowerStatusToken_
Definition: EcalDBCopy.h:109
edm::ESGetToken< EcalLaserAPDPNRatios, EcalLaserAPDPNRatiosRcd > ecalLaserAPDPNRatiosToken_
Definition: EcalDBCopy.h:120
edm::ESGetToken< EcalClusterCrackCorrParameters, EcalClusterCrackCorrParametersRcd > ecalClusterCrackCorrParametersToken_
Definition: EcalDBCopy.h:123
edm::ESGetToken< EcalSampleMask, EcalSampleMaskRcd > ecalSampleMaskToken_
Definition: EcalDBCopy.h:138
edm::ESGetToken< EcalChannelStatus, EcalChannelStatusRcd > ecalChannelStatusToken_
Definition: EcalDBCopy.h:105
edm::ESGetToken< EcalTimeOffsetConstant, EcalTimeOffsetConstantRcd > ecalTimeOffsetConstantToken_
Definition: EcalDBCopy.h:137
edm::ESGetToken< EcalLaserAPDPNRatiosRef, EcalLaserAPDPNRatiosRefRcd > ecalLaserAPDPNRatiosRefToken_
Definition: EcalDBCopy.h:121
edm::ESGetToken< EcalADCToGeVConstant, EcalADCToGeVConstantRcd > ecalADCtoGeVToken_
Definition: EcalDBCopy.h:103
std::vector< AlignmentParameters * > Parameters
Definition: Utilities.h:32
edm::ESGetToken< EcalDQMChannelStatus, EcalDQMChannelStatusRcd > ecalDQMChannelStatusToken_
Definition: EcalDBCopy.h:106
edm::ESGetToken< EcalTPGCrystalStatus, EcalTPGCrystalStatusRcd > ecalTPGCrystalStatusToken_
Definition: EcalDBCopy.h:110
std::map< std::string, unsigned long long > m_cacheIDs
Definition: EcalDBCopy.h:100
edm::ESGetToken< EcalIntercalibConstantsMC, EcalIntercalibConstantsMCRcd > ecalIntercalibConstantsMCToken_
Definition: EcalDBCopy.h:114

◆ ~EcalDBCopy()

EcalDBCopy::~EcalDBCopy ( )
override

Definition at line 112 of file EcalDBCopy.cc.

112 {}

Member Function Documentation

◆ analyze()

void EcalDBCopy::analyze ( const edm::Event evt,
const edm::EventSetup evtSetup 
)
overridevirtual

Implements edm::one::EDAnalyzerBase.

Definition at line 114 of file EcalDBCopy.cc.

References copyToDB(), m_records, and shouldCopy().

114  {
115  for (const auto& irec : m_records) {
116  if (shouldCopy(evtSetup, irec.first)) {
117  copyToDB(evtSetup, irec.first);
118  }
119  }
120 }
void copyToDB(const edm::EventSetup &evtSetup, const std::string &container)
Definition: EcalDBCopy.cc:208
std::map< std::string, std::string > m_records
Definition: EcalDBCopy.h:101
bool shouldCopy(const edm::EventSetup &evtSetup, const std::string &container)
Definition: EcalDBCopy.cc:122

◆ copyToDB()

void EcalDBCopy::copyToDB ( const edm::EventSetup evtSetup,
const std::string &  container 
)
private

Definition at line 208 of file EcalDBCopy.cc.

References cond::service::PoolDBOutputService::beginOfTime(), filterCSVwithJSON::copy, cond::service::PoolDBOutputService::createOneIOV(), ebAlignmentToken_, EcalSamplesCorrelation::EBG12SamplesCorrelation, EcalSamplesCorrelation::EBG1SamplesCorrelation, EcalSamplesCorrelation::EBG6SamplesCorrelation, EcalTimeBiasCorrections::EBTimeCorrAmplitudeBins, EcalTimeBiasCorrections::EBTimeCorrShiftBins, ecalADCtoGeVToken_, ecalChannelStatusToken_, ecalClusterCrackCorrParametersToken_, ecalClusterEnergyCorrectionObjectSpecificParametersToken_, ecalClusterEnergyCorrectionParametersToken_, ecalClusterEnergyUncertaintyParametersToken_, ecalClusterLocalContCorrParametersToken_, ecalDAQTowerStatusToken_, ecalDCSTowerStatusToken_, ecalDQMChannelStatusToken_, ecalDQMTowerStatusToken_, ecalGainRatiosToken_, ecalIntercalibConstantsMCToken_, ecalIntercalibConstantsToken_, ecalIntercalibErrorsToken_, ecalLaserAlphasToken_, ecalLaserAPDPNRatiosRefToken_, ecalLaserAPDPNRatiosToken_, ecalLinearCorrectionsToken_, ecalPedestalToken_, ecalPFRecHitThresholdsToken_, ecalSampleMaskToken_, ecalSamplesCorrelationToken_, ecalSimComponentShapeToken_, ecalSimPulseShapeToken_, ecalTBWeightsToken_, ecalTimeBiasCorrectionsToken_, ecalTimeCalibToken_, ecalTimeOffsetConstantToken_, ecalTPGCrystalStatusToken_, ecalTPGTowerStatusToken_, ecalWeightXtalGroupsToken_, eeAlignmentToken_, EcalSamplesCorrelation::EEG12SamplesCorrelation, EcalSamplesCorrelation::EEG1SamplesCorrelation, EcalSamplesCorrelation::EEG6SamplesCorrelation, EcalTimeBiasCorrections::EETimeCorrAmplitudeBins, EcalTimeBiasCorrections::EETimeCorrShiftBins, esAlignmentToken_, Exception, edm::EventSetup::getData(), edm::Service< T >::isAvailable(), m_records, getGTfromDQMFile::obj, align_cfg::recordName, AlCaHLTBitMon_QueryRunRegistry::string, and cond::service::PoolDBOutputService::writeOneIOV().

Referenced by analyze().

208  {
210  if (!dbOutput.isAvailable()) {
211  throw cms::Exception("PoolDBOutputService is not available");
212  }
213 
214  std::string recordName = m_records[container];
215 
216  if (container == "EcalPedestals") {
217  const auto& obj = evtSetup.getData(ecalPedestalToken_);
218  edm::LogInfo("EcalDBCopy") << "ped pointer is: " << &obj << std::endl;
219  dbOutput->createOneIOV<const EcalPedestals>(obj, dbOutput->beginOfTime(), recordName);
220 
221  } else if (container == "EcalADCToGeVConstant") {
222  const auto& obj = evtSetup.getData(ecalADCtoGeVToken_);
223  edm::LogInfo("EcalDBCopy") << "adc pointer is: " << &obj << std::endl;
224  dbOutput->createOneIOV<const EcalADCToGeVConstant>(obj, dbOutput->beginOfTime(), recordName);
225 
226  } else if (container == "EcalTimeCalibConstants") {
227  const auto& obj = evtSetup.getData(ecalTimeCalibToken_);
228  edm::LogInfo("EcalDBCopy") << "adc pointer is: " << &obj << std::endl;
229  dbOutput->createOneIOV<const EcalTimeCalibConstants>(obj, dbOutput->beginOfTime(), recordName);
230 
231  } else if (container == "EcalChannelStatus") {
232  const auto& obj = evtSetup.getData(ecalChannelStatusToken_);
233  edm::LogInfo("EcalDBCopy") << "channel status pointer is: " << &obj << std::endl;
234  dbOutput->createOneIOV<const EcalChannelStatus>(obj, dbOutput->beginOfTime(), recordName);
235 
236  } else if (container == "EcalDQMChannelStatus") {
237  const auto& obj = evtSetup.getData(ecalDQMChannelStatusToken_);
238  edm::LogInfo("EcalDBCopy") << "DQM channel status pointer is: " << &obj << std::endl;
239  dbOutput->createOneIOV<const EcalDQMChannelStatus>(obj, dbOutput->beginOfTime(), recordName);
240 
241  } else if (container == "EcalDQMTowerStatus") {
242  const auto& obj = evtSetup.getData(ecalDQMTowerStatusToken_);
243  edm::LogInfo("EcalDBCopy") << "DQM Tower status pointer is: " << &obj << std::endl;
244  dbOutput->createOneIOV<const EcalDQMTowerStatus>(obj, dbOutput->beginOfTime(), recordName);
245 
246  } else if (container == "EcalDCSTowerStatus") {
247  const auto& obj = evtSetup.getData(ecalDCSTowerStatusToken_);
248  edm::LogInfo("EcalDBCopy") << "channel status pointer is: " << &obj << std::endl;
249  dbOutput->createOneIOV<const EcalDCSTowerStatus>(obj, dbOutput->beginOfTime(), recordName);
250 
251  } else if (container == "EcalDAQTowerStatus") {
252  const auto& obj = evtSetup.getData(ecalDAQTowerStatusToken_);
253  edm::LogInfo("EcalDBCopy") << "DAQ channel status pointer is: " << &obj << std::endl;
254  dbOutput->createOneIOV<const EcalDAQTowerStatus>(obj, dbOutput->beginOfTime(), recordName);
255 
256  } else if (container == "EcalTPGCrystalStatus") {
257  const auto& obj = evtSetup.getData(ecalTPGCrystalStatusToken_);
258  edm::LogInfo("EcalDBCopy") << "TPG channel status pointer is: " << &obj << std::endl;
259  dbOutput->createOneIOV<const EcalTPGCrystalStatus>(obj, dbOutput->beginOfTime(), recordName);
260 
261  } else if (container == "EcalTPGTowerStatus") {
262  const auto& obj = evtSetup.getData(ecalTPGTowerStatusToken_);
263  edm::LogInfo("EcalDBCopy") << "TPG tower status pointer is: " << &obj << std::endl;
264  dbOutput->createOneIOV<const EcalTPGTowerStatus>(obj, dbOutput->beginOfTime(), recordName);
265 
266  } else if (container == "EcalIntercalibConstants") {
267  const auto& obj = evtSetup.getData(ecalIntercalibConstantsToken_);
268  edm::LogInfo("EcalDBCopy") << "inter pointer is: " << &obj << std::endl;
269  dbOutput->createOneIOV<const EcalIntercalibConstants>(obj, dbOutput->beginOfTime(), recordName);
270 
271  } else if (container == "EcalLinearCorrections") {
272  const auto& obj = evtSetup.getData(ecalLinearCorrectionsToken_);
273  edm::LogInfo("EcalDBCopy") << "inter pointer is: " << &obj << std::endl;
274  dbOutput->createOneIOV<const EcalLinearCorrections>(obj, dbOutput->beginOfTime(), recordName);
275 
276  } else if (container == "EcalIntercalibConstantsMC") {
277  const auto& obj = evtSetup.getData(ecalIntercalibConstantsMCToken_);
278  edm::LogInfo("EcalDBCopy") << "intercalib MC pointer is: " << &obj << std::endl;
279  dbOutput->createOneIOV<const EcalIntercalibConstantsMC>(obj, dbOutput->beginOfTime(), recordName);
280 
281  } else if (container == "EcalIntercalibErrors") {
282  const auto& obj = evtSetup.getData(ecalIntercalibErrorsToken_);
283  edm::LogInfo("EcalDBCopy") << "inter pointer is: " << &obj << std::endl;
284  dbOutput->createOneIOV<const EcalIntercalibErrors>(obj, dbOutput->beginOfTime(), recordName);
285 
286  } else if (container == "EcalGainRatios") {
287  const auto& obj = evtSetup.getData(ecalGainRatiosToken_);
288  edm::LogInfo("EcalDBCopy") << "gain pointer is: " << &obj << std::endl;
289  dbOutput->createOneIOV<const EcalGainRatios>(obj, dbOutput->beginOfTime(), recordName);
290 
291  } else if (container == "EcalWeightXtalGroups") {
292  const auto& obj = evtSetup.getData(ecalWeightXtalGroupsToken_);
293  edm::LogInfo("EcalDBCopy") << "weight pointer is: " << &obj << std::endl;
294  dbOutput->createOneIOV<const EcalWeightXtalGroups>(obj, dbOutput->beginOfTime(), recordName);
295 
296  } else if (container == "EcalTBWeights") {
297  const auto& obj = evtSetup.getData(ecalTBWeightsToken_);
298  edm::LogInfo("EcalDBCopy") << "tbweight pointer is: " << &obj << std::endl;
299  dbOutput->createOneIOV<const EcalTBWeights>(obj, dbOutput->beginOfTime(), recordName);
300 
301  } else if (container == "EcalLaserAlphas") {
302  const auto& obj = evtSetup.getData(ecalLaserAlphasToken_);
303  edm::LogInfo("EcalDBCopy") << "ecalLaserAlpha pointer is: " << &obj << std::endl;
304  dbOutput->createOneIOV<const EcalLaserAlphas>(obj, dbOutput->beginOfTime(), recordName);
305 
306  } else if (container == "EcalLaserAPDPNRatios") {
307  const auto& obj = evtSetup.getData(ecalLaserAPDPNRatiosToken_);
308  edm::LogInfo("EcalDBCopy") << "tbweight pointer is: " << &obj << std::endl;
309  dbOutput->createOneIOV<const EcalLaserAPDPNRatios>(obj, dbOutput->beginOfTime(), recordName);
310 
311  } else if (container == "EcalLaserAPDPNRatiosRef") {
312  const auto& obj = evtSetup.getData(ecalLaserAPDPNRatiosRefToken_);
313  edm::LogInfo("EcalDBCopy") << "tbweight pointer is: " << &obj << std::endl;
314  dbOutput->createOneIOV<const EcalLaserAPDPNRatiosRef>(obj, dbOutput->beginOfTime(), recordName);
315 
316  } else if (container == "EcalClusterCrackCorrParameters") {
317  const auto& obj = evtSetup.getData(ecalClusterCrackCorrParametersToken_);
318  edm::LogInfo("EcalDBCopy") << "cluster crack pointer is: " << &obj << std::endl;
319  dbOutput->createOneIOV<const EcalClusterCrackCorrParameters>(obj, dbOutput->beginOfTime(), recordName);
320 
321  } else if (container == "EcalPFRecHitThresholds") {
322  const auto& obj = evtSetup.getData(ecalPFRecHitThresholdsToken_);
323  edm::LogInfo("EcalDBCopy") << "Ecal PF rec hit thresholds pointer is: " << &obj << std::endl;
324  dbOutput->createOneIOV<const EcalPFRecHitThresholds>(obj, dbOutput->beginOfTime(), recordName);
325 
326  } else if (container == "EcalClusterEnergyUncertaintyParameters") {
328  edm::LogInfo("EcalDBCopy") << "tbweight pointer is: " << &obj << std::endl;
330 
331  } else if (container == "EcalClusterEnergyCorrectionParameters") {
333  edm::LogInfo("EcalDBCopy") << "tbweight pointer is: " << &obj << std::endl;
335 
336  } else if (container == "EcalClusterEnergyCorrectionObjectSpecificParameters") {
338  edm::LogInfo("EcalDBCopy") << "tbweight pointer is: " << &obj << std::endl;
340  obj, dbOutput->beginOfTime(), recordName);
341 
342  } else if (container == "EcalClusterLocalContCorrParameters") {
343  const auto& obj = evtSetup.getData(ecalClusterLocalContCorrParametersToken_);
344  edm::LogInfo("EcalDBCopy") << "tbweight pointer is: " << &obj << std::endl;
346 
347  } else if (container == "EBAlignment") {
348  const auto& obj = evtSetup.getData(ebAlignmentToken_);
349  edm::LogInfo("EcalDBCopy") << "EB alignment pointer is: " << &obj << std::endl;
350  dbOutput->createOneIOV<const Alignments>(obj, dbOutput->beginOfTime(), recordName);
351 
352  } else if (container == "EEAlignment") {
353  const auto& obj = evtSetup.getData(eeAlignmentToken_);
354  edm::LogInfo("EcalDBCopy") << "EE alignment pointer is: " << &obj << std::endl;
355  dbOutput->createOneIOV<const Alignments>(obj, dbOutput->beginOfTime(), recordName);
356 
357  } else if (container == "ESAlignment") {
358  const auto& obj = evtSetup.getData(esAlignmentToken_);
359  edm::LogInfo("EcalDBCopy") << "ES alignment pointer is: " << &obj << std::endl;
360  dbOutput->createOneIOV<const Alignments>(obj, dbOutput->beginOfTime(), recordName);
361 
362  } else if (container == "EcalTimeOffsetConstant") {
363  const auto& obj = evtSetup.getData(ecalTimeOffsetConstantToken_);
364  edm::LogInfo("EcalDBCopy") << "TimeOffset pointer is: " << &obj << std::endl;
365  dbOutput->createOneIOV<const EcalTimeOffsetConstant>(obj, dbOutput->beginOfTime(), recordName);
366 
367  } else if (container == "EcalSampleMask") {
368  const auto& obj = evtSetup.getData(ecalSampleMaskToken_);
369  edm::LogInfo("EcalDBCopy") << "sample mask pointer is: " << &obj << std::endl;
370  dbOutput->createOneIOV<const EcalSampleMask>(obj, dbOutput->beginOfTime(), recordName);
371 
372  } else if (container == "EcalSimComponentShape") {
373  const auto& obj = evtSetup.getData(ecalSimComponentShapeToken_);
374  dbOutput->createOneIOV<const EcalSimComponentShape>(obj, dbOutput->beginOfTime(), recordName);
375 
376  } else if (container == "EcalSimPulseShape") {
377  const auto& obj = evtSetup.getData(ecalSimPulseShapeToken_);
378  dbOutput->createOneIOV<const EcalSimPulseShape>(obj, dbOutput->beginOfTime(), recordName);
379 
380  } else if (container == "EcalTimeBiasCorrections") {
381  const auto& obj = evtSetup.getData(ecalTimeBiasCorrectionsToken_);
382  edm::LogInfo("EcalDBCopy") << "TimeBiasCorrections pointer is: " << &obj << std::endl;
384  std::vector<float> vect = obj.EBTimeCorrAmplitudeBins;
385  copy(vect.begin(), vect.end(), back_inserter(bias_.EBTimeCorrAmplitudeBins));
386  vect = obj.EBTimeCorrShiftBins;
387  copy(vect.begin(), vect.end(), back_inserter(bias_.EBTimeCorrShiftBins));
388  vect = obj.EETimeCorrAmplitudeBins;
389  copy(vect.begin(), vect.end(), back_inserter(bias_.EETimeCorrAmplitudeBins));
390  vect = obj.EETimeCorrShiftBins;
391  copy(vect.begin(), vect.end(), back_inserter(bias_.EETimeCorrShiftBins));
392  dbOutput->writeOneIOV(bias_, dbOutput->beginOfTime(), "EcalTimeBiasCorrectionsRcd");
393 
394  } else if (container == "EcalSamplesCorrelation") {
395  const auto& obj = evtSetup.getData(ecalSamplesCorrelationToken_);
396  edm::LogInfo("EcalDBCopy") << "SamplesCorrelation pointer is: " << &obj << std::endl;
397  EcalSamplesCorrelation correl_;
398  std::vector<double> vect = obj.EBG12SamplesCorrelation;
399  copy(vect.begin(), vect.end(), back_inserter(correl_.EBG12SamplesCorrelation));
400  vect = obj.EBG6SamplesCorrelation;
401  copy(vect.begin(), vect.end(), back_inserter(correl_.EBG6SamplesCorrelation));
402  vect = obj.EBG1SamplesCorrelation;
403  copy(vect.begin(), vect.end(), back_inserter(correl_.EBG1SamplesCorrelation));
404  vect = obj.EEG12SamplesCorrelation;
405  copy(vect.begin(), vect.end(), back_inserter(correl_.EEG12SamplesCorrelation));
406  vect = obj.EEG6SamplesCorrelation;
407  copy(vect.begin(), vect.end(), back_inserter(correl_.EEG6SamplesCorrelation));
408  vect = obj.EEG1SamplesCorrelation;
409  copy(vect.begin(), vect.end(), back_inserter(correl_.EEG1SamplesCorrelation));
410  dbOutput->writeOneIOV(correl_, dbOutput->beginOfTime(), "EcalSamplesCorrelationRcd");
411 
412  } else {
413  throw cms::Exception("Unknown container");
414  }
415 
416  edm::LogInfo("EcalDBCopy") << "EcalDBCopy wrote " << recordName << std::endl;
417 }
edm::ESGetToken< EcalDQMTowerStatus, EcalDQMTowerStatusRcd > ecalDQMTowerStatusToken_
Definition: EcalDBCopy.h:107
edm::ESGetToken< EcalIntercalibConstants, EcalIntercalibConstantsRcd > ecalIntercalibConstantsToken_
Definition: EcalDBCopy.h:112
std::vector< float > EBTimeCorrShiftBins
edm::ESGetToken< EcalTBWeights, EcalTBWeightsRcd > ecalTBWeightsToken_
Definition: EcalDBCopy.h:118
T const & getData(const ESGetToken< T, R > &iToken) const noexcept(false)
Definition: EventSetup.h:119
edm::ESGetToken< EcalLaserAlphas, EcalLaserAlphasRcd > ecalLaserAlphasToken_
Definition: EcalDBCopy.h:119
std::map< std::string, std::string > m_records
Definition: EcalDBCopy.h:101
edm::ESGetToken< EcalIntercalibErrors, EcalIntercalibErrorsRcd > ecalIntercalibErrorsToken_
Definition: EcalDBCopy.h:115
std::vector< double > EBG12SamplesCorrelation
edm::ESGetToken< Alignments, EBAlignmentRcd > ebAlignmentToken_
Definition: EcalDBCopy.h:134
edm::ESGetToken< EcalSamplesCorrelation, EcalSamplesCorrelationRcd > ecalSamplesCorrelationToken_
Definition: EcalDBCopy.h:142
edm::ESGetToken< EcalWeightXtalGroups, EcalWeightXtalGroupsRcd > ecalWeightXtalGroupsToken_
Definition: EcalDBCopy.h:117
edm::ESGetToken< EcalTimeBiasCorrections, EcalTimeBiasCorrectionsRcd > ecalTimeBiasCorrectionsToken_
Definition: EcalDBCopy.h:141
edm::ESGetToken< EcalDCSTowerStatus, EcalDCSTowerStatusRcd > ecalDCSTowerStatusToken_
Definition: EcalDBCopy.h:108
edm::ESGetToken< EcalPFRecHitThresholds, EcalPFRecHitThresholdsRcd > ecalPFRecHitThresholdsToken_
Definition: EcalDBCopy.h:124
edm::ESGetToken< EcalGainRatios, EcalGainRatiosRcd > ecalGainRatiosToken_
Definition: EcalDBCopy.h:116
void createOneIOV(const T &payload, cond::Time_t firstSinceTime, const std::string &recordName)
std::vector< double > EBG6SamplesCorrelation
std::vector< float > EBTimeCorrAmplitudeBins
std::vector< float > EETimeCorrShiftBins
edm::ESGetToken< EcalClusterLocalContCorrParameters, EcalClusterLocalContCorrParametersRcd > ecalClusterLocalContCorrParametersToken_
Definition: EcalDBCopy.h:133
edm::ESGetToken< EcalSimPulseShape, EcalSimPulseShapeRcd > ecalSimPulseShapeToken_
Definition: EcalDBCopy.h:140
edm::ESGetToken< EcalTimeCalibConstants, EcalTimeCalibConstantsRcd > ecalTimeCalibToken_
Definition: EcalDBCopy.h:104
std::vector< float > EETimeCorrAmplitudeBins
edm::ESGetToken< EcalClusterEnergyUncertaintyParameters, EcalClusterEnergyUncertaintyParametersRcd > ecalClusterEnergyUncertaintyParametersToken_
Definition: EcalDBCopy.h:126
edm::ESGetToken< EcalSimComponentShape, EcalSimComponentShapeRcd > ecalSimComponentShapeToken_
Definition: EcalDBCopy.h:139
Hash writeOneIOV(const T &payload, Time_t time, const std::string &recordName)
edm::ESGetToken< EcalLinearCorrections, EcalLinearCorrectionsRcd > ecalLinearCorrectionsToken_
Definition: EcalDBCopy.h:113
edm::ESGetToken< EcalClusterEnergyCorrectionParameters, EcalClusterEnergyCorrectionParametersRcd > ecalClusterEnergyCorrectionParametersToken_
Definition: EcalDBCopy.h:128
edm::ESGetToken< EcalClusterEnergyCorrectionObjectSpecificParameters, EcalClusterEnergyCorrectionObjectSpecificParametersRcd > ecalClusterEnergyCorrectionObjectSpecificParametersToken_
Definition: EcalDBCopy.h:131
edm::ESGetToken< Alignments, ESAlignmentRcd > esAlignmentToken_
Definition: EcalDBCopy.h:136
edm::ESGetToken< EcalPedestals, EcalPedestalsRcd > ecalPedestalToken_
Definition: EcalDBCopy.h:102
edm::ESGetToken< Alignments, EEAlignmentRcd > eeAlignmentToken_
Definition: EcalDBCopy.h:135
edm::ESGetToken< EcalTPGTowerStatus, EcalTPGTowerStatusRcd > ecalTPGTowerStatusToken_
Definition: EcalDBCopy.h:111
edm::ESGetToken< EcalDAQTowerStatus, EcalDAQTowerStatusRcd > ecalDAQTowerStatusToken_
Definition: EcalDBCopy.h:109
Log< level::Info, false > LogInfo
edm::ESGetToken< EcalLaserAPDPNRatios, EcalLaserAPDPNRatiosRcd > ecalLaserAPDPNRatiosToken_
Definition: EcalDBCopy.h:120
edm::ESGetToken< EcalClusterCrackCorrParameters, EcalClusterCrackCorrParametersRcd > ecalClusterCrackCorrParametersToken_
Definition: EcalDBCopy.h:123
std::vector< double > EBG1SamplesCorrelation
edm::ESGetToken< EcalSampleMask, EcalSampleMaskRcd > ecalSampleMaskToken_
Definition: EcalDBCopy.h:138
edm::ESGetToken< EcalChannelStatus, EcalChannelStatusRcd > ecalChannelStatusToken_
Definition: EcalDBCopy.h:105
edm::ESGetToken< EcalTimeOffsetConstant, EcalTimeOffsetConstantRcd > ecalTimeOffsetConstantToken_
Definition: EcalDBCopy.h:137
edm::ESGetToken< EcalLaserAPDPNRatiosRef, EcalLaserAPDPNRatiosRefRcd > ecalLaserAPDPNRatiosRefToken_
Definition: EcalDBCopy.h:121
edm::ESGetToken< EcalADCToGeVConstant, EcalADCToGeVConstantRcd > ecalADCtoGeVToken_
Definition: EcalDBCopy.h:103
edm::ESGetToken< EcalDQMChannelStatus, EcalDQMChannelStatusRcd > ecalDQMChannelStatusToken_
Definition: EcalDBCopy.h:106
std::vector< double > EEG1SamplesCorrelation
bool isAvailable() const
Definition: Service.h:40
std::vector< double > EEG12SamplesCorrelation
edm::ESGetToken< EcalTPGCrystalStatus, EcalTPGCrystalStatusRcd > ecalTPGCrystalStatusToken_
Definition: EcalDBCopy.h:110
std::vector< double > EEG6SamplesCorrelation
edm::ESGetToken< EcalIntercalibConstantsMC, EcalIntercalibConstantsMCRcd > ecalIntercalibConstantsMCToken_
Definition: EcalDBCopy.h:114

◆ shouldCopy()

bool EcalDBCopy::shouldCopy ( const edm::EventSetup evtSetup,
const std::string &  container 
)
private

Definition at line 122 of file EcalDBCopy.cc.

References Exception, edm::EventSetup::get(), and m_cacheIDs.

Referenced by analyze().

122  {
123  unsigned long long cacheID = 0;
124  if (container == "EcalPedestals") {
125  cacheID = evtSetup.get<EcalPedestalsRcd>().cacheIdentifier();
126  } else if (container == "EcalADCToGeVConstant") {
127  cacheID = evtSetup.get<EcalADCToGeVConstantRcd>().cacheIdentifier();
128  } else if (container == "EcalLinearCorrections") {
129  cacheID = evtSetup.get<EcalLinearCorrectionsRcd>().cacheIdentifier();
130  } else if (container == "EcalIntercalibConstants") {
131  cacheID = evtSetup.get<EcalIntercalibConstantsRcd>().cacheIdentifier();
132  } else if (container == "EcalIntercalibConstantsMC") {
133  cacheID = evtSetup.get<EcalIntercalibConstantsMCRcd>().cacheIdentifier();
134  } else if (container == "EcalIntercalibErrors") {
135  cacheID = evtSetup.get<EcalIntercalibErrorsRcd>().cacheIdentifier();
136  } else if (container == "EcalGainRatios") {
137  cacheID = evtSetup.get<EcalGainRatiosRcd>().cacheIdentifier();
138  } else if (container == "EcalWeightXtalGroups") {
139  cacheID = evtSetup.get<EcalWeightXtalGroupsRcd>().cacheIdentifier();
140  } else if (container == "EcalTBWeights") {
141  cacheID = evtSetup.get<EcalTBWeightsRcd>().cacheIdentifier();
142  } else if (container == "EcalLaserAPDPNRatios") {
143  cacheID = evtSetup.get<EcalLaserAPDPNRatiosRcd>().cacheIdentifier();
144  } else if (container == "EcalLaserAPDPNRatiosRef") {
145  cacheID = evtSetup.get<EcalTBWeightsRcd>().cacheIdentifier();
146  } else if (container == "EcalLaserAlphas") {
147  cacheID = evtSetup.get<EcalTBWeightsRcd>().cacheIdentifier();
148  } else if (container == "EcalChannelStatus") {
149  cacheID = evtSetup.get<EcalChannelStatusRcd>().cacheIdentifier();
150  } else if (container == "EcalDQMTowerStatus") {
151  cacheID = evtSetup.get<EcalDQMTowerStatusRcd>().cacheIdentifier();
152  } else if (container == "EcalDQMChannelStatus") {
153  cacheID = evtSetup.get<EcalDQMChannelStatusRcd>().cacheIdentifier();
154  } else if (container == "EcalDCSTowerStatus") {
155  cacheID = evtSetup.get<EcalDCSTowerStatusRcd>().cacheIdentifier();
156  } else if (container == "EcalDAQTowerStatus") {
157  cacheID = evtSetup.get<EcalDAQTowerStatusRcd>().cacheIdentifier();
158  } else if (container == "EcalTimeCalibConstants") {
159  cacheID = evtSetup.get<EcalTimeCalibConstantsRcd>().cacheIdentifier();
160  } else if (container == "EcalClusterCrackCorrParameters") {
161  cacheID = evtSetup.get<EcalClusterCrackCorrParametersRcd>().cacheIdentifier();
162  } else if (container == "EcalPFRecHitThresholds") {
163  cacheID = evtSetup.get<EcalPFRecHitThresholdsRcd>().cacheIdentifier();
164  } else if (container == "EcalClusterEnergyUncertaintyParameters") {
165  cacheID = evtSetup.get<EcalClusterEnergyUncertaintyParametersRcd>().cacheIdentifier();
166  } else if (container == "EcalClusterEnergyCorrectionParameters") {
167  cacheID = evtSetup.get<EcalClusterEnergyCorrectionParametersRcd>().cacheIdentifier();
168  } else if (container == "EcalClusterEnergyCorrectionObjectSpecificParameters") {
169  cacheID = evtSetup.get<EcalClusterEnergyCorrectionObjectSpecificParametersRcd>().cacheIdentifier();
170  } else if (container == "EcalClusterLocalContCorrParameters") {
171  cacheID = evtSetup.get<EcalClusterLocalContCorrParametersRcd>().cacheIdentifier();
172  } else if (container == "EcalTPGCrystalStatus") {
173  cacheID = evtSetup.get<EcalTPGCrystalStatusRcd>().cacheIdentifier();
174  } else if (container == "EcalTPGTowerStatus") {
175  cacheID = evtSetup.get<EcalTPGTowerStatusRcd>().cacheIdentifier();
176  } else if (container == "EBAlignment") {
177  cacheID = evtSetup.get<EBAlignmentRcd>().cacheIdentifier();
178  } else if (container == "EEAlignment") {
179  cacheID = evtSetup.get<EEAlignmentRcd>().cacheIdentifier();
180  } else if (container == "ESAlignment") {
181  cacheID = evtSetup.get<ESAlignmentRcd>().cacheIdentifier();
182  } else if (container == "EcalTimeOffsetConstant") {
183  cacheID = evtSetup.get<EcalTimeOffsetConstantRcd>().cacheIdentifier();
184  } else if (container == "EcalSampleMask") {
185  cacheID = evtSetup.get<EcalSampleMaskRcd>().cacheIdentifier();
186  } else if (container == "EcalTimeBiasCorrections") {
187  cacheID = evtSetup.get<EcalTimeBiasCorrectionsRcd>().cacheIdentifier();
188  } else if (container == "EcalSimComponentShape") {
189  cacheID = evtSetup.get<EcalSimComponentShapeRcd>().cacheIdentifier();
190  } else if (container == "EcalSimPulseShape") {
191  cacheID = evtSetup.get<EcalSimPulseShapeRcd>().cacheIdentifier();
192  } else if (container == "EcalSamplesCorrelation") {
193  cacheID = evtSetup.get<EcalSamplesCorrelationRcd>().cacheIdentifier();
194  }
195 
196  else {
197  throw cms::Exception("Unknown container");
198  }
199 
200  if (m_cacheIDs[container] == cacheID) {
201  return false;
202  } else {
203  m_cacheIDs[container] = cacheID;
204  return true;
205  }
206 }
T get() const
Definition: EventSetup.h:79
std::map< std::string, unsigned long long > m_cacheIDs
Definition: EcalDBCopy.h:100

Member Data Documentation

◆ ebAlignmentToken_

edm::ESGetToken<Alignments, EBAlignmentRcd> EcalDBCopy::ebAlignmentToken_
private

Definition at line 134 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalADCtoGeVToken_

edm::ESGetToken<EcalADCToGeVConstant, EcalADCToGeVConstantRcd> EcalDBCopy::ecalADCtoGeVToken_
private

Definition at line 103 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalChannelStatusToken_

edm::ESGetToken<EcalChannelStatus, EcalChannelStatusRcd> EcalDBCopy::ecalChannelStatusToken_
private

Definition at line 105 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalClusterCrackCorrParametersToken_

edm::ESGetToken<EcalClusterCrackCorrParameters, EcalClusterCrackCorrParametersRcd> EcalDBCopy::ecalClusterCrackCorrParametersToken_
private

Definition at line 123 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalClusterEnergyCorrectionObjectSpecificParametersToken_

edm::ESGetToken<EcalClusterEnergyCorrectionObjectSpecificParameters, EcalClusterEnergyCorrectionObjectSpecificParametersRcd> EcalDBCopy::ecalClusterEnergyCorrectionObjectSpecificParametersToken_
private

Definition at line 131 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalClusterEnergyCorrectionParametersToken_

edm::ESGetToken<EcalClusterEnergyCorrectionParameters, EcalClusterEnergyCorrectionParametersRcd> EcalDBCopy::ecalClusterEnergyCorrectionParametersToken_
private

Definition at line 128 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalClusterEnergyUncertaintyParametersToken_

edm::ESGetToken<EcalClusterEnergyUncertaintyParameters, EcalClusterEnergyUncertaintyParametersRcd> EcalDBCopy::ecalClusterEnergyUncertaintyParametersToken_
private

Definition at line 126 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalClusterLocalContCorrParametersToken_

edm::ESGetToken<EcalClusterLocalContCorrParameters, EcalClusterLocalContCorrParametersRcd> EcalDBCopy::ecalClusterLocalContCorrParametersToken_
private

Definition at line 133 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalDAQTowerStatusToken_

edm::ESGetToken<EcalDAQTowerStatus, EcalDAQTowerStatusRcd> EcalDBCopy::ecalDAQTowerStatusToken_
private

Definition at line 109 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalDCSTowerStatusToken_

edm::ESGetToken<EcalDCSTowerStatus, EcalDCSTowerStatusRcd> EcalDBCopy::ecalDCSTowerStatusToken_
private

Definition at line 108 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalDQMChannelStatusToken_

edm::ESGetToken<EcalDQMChannelStatus, EcalDQMChannelStatusRcd> EcalDBCopy::ecalDQMChannelStatusToken_
private

Definition at line 106 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalDQMTowerStatusToken_

edm::ESGetToken<EcalDQMTowerStatus, EcalDQMTowerStatusRcd> EcalDBCopy::ecalDQMTowerStatusToken_
private

Definition at line 107 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalGainRatiosToken_

edm::ESGetToken<EcalGainRatios, EcalGainRatiosRcd> EcalDBCopy::ecalGainRatiosToken_
private

Definition at line 116 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalIntercalibConstantsMCToken_

edm::ESGetToken<EcalIntercalibConstantsMC, EcalIntercalibConstantsMCRcd> EcalDBCopy::ecalIntercalibConstantsMCToken_
private

Definition at line 114 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalIntercalibConstantsToken_

edm::ESGetToken<EcalIntercalibConstants, EcalIntercalibConstantsRcd> EcalDBCopy::ecalIntercalibConstantsToken_
private

Definition at line 112 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalIntercalibErrorsToken_

edm::ESGetToken<EcalIntercalibErrors, EcalIntercalibErrorsRcd> EcalDBCopy::ecalIntercalibErrorsToken_
private

Definition at line 115 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalLaserAlphasToken_

edm::ESGetToken<EcalLaserAlphas, EcalLaserAlphasRcd> EcalDBCopy::ecalLaserAlphasToken_
private

Definition at line 119 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalLaserAPDPNRatiosRefToken_

edm::ESGetToken<EcalLaserAPDPNRatiosRef, EcalLaserAPDPNRatiosRefRcd> EcalDBCopy::ecalLaserAPDPNRatiosRefToken_
private

Definition at line 121 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalLaserAPDPNRatiosToken_

edm::ESGetToken<EcalLaserAPDPNRatios, EcalLaserAPDPNRatiosRcd> EcalDBCopy::ecalLaserAPDPNRatiosToken_
private

Definition at line 120 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalLinearCorrectionsToken_

edm::ESGetToken<EcalLinearCorrections, EcalLinearCorrectionsRcd> EcalDBCopy::ecalLinearCorrectionsToken_
private

Definition at line 113 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalPedestalToken_

edm::ESGetToken<EcalPedestals, EcalPedestalsRcd> EcalDBCopy::ecalPedestalToken_
private

Definition at line 102 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalPFRecHitThresholdsToken_

edm::ESGetToken<EcalPFRecHitThresholds, EcalPFRecHitThresholdsRcd> EcalDBCopy::ecalPFRecHitThresholdsToken_
private

Definition at line 124 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalSampleMaskToken_

edm::ESGetToken<EcalSampleMask, EcalSampleMaskRcd> EcalDBCopy::ecalSampleMaskToken_
private

Definition at line 138 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalSamplesCorrelationToken_

edm::ESGetToken<EcalSamplesCorrelation, EcalSamplesCorrelationRcd> EcalDBCopy::ecalSamplesCorrelationToken_
private

Definition at line 142 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalSimComponentShapeToken_

edm::ESGetToken<EcalSimComponentShape, EcalSimComponentShapeRcd> EcalDBCopy::ecalSimComponentShapeToken_
private

Definition at line 139 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalSimPulseShapeToken_

edm::ESGetToken<EcalSimPulseShape, EcalSimPulseShapeRcd> EcalDBCopy::ecalSimPulseShapeToken_
private

Definition at line 140 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalTBWeightsToken_

edm::ESGetToken<EcalTBWeights, EcalTBWeightsRcd> EcalDBCopy::ecalTBWeightsToken_
private

Definition at line 118 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalTimeBiasCorrectionsToken_

edm::ESGetToken<EcalTimeBiasCorrections, EcalTimeBiasCorrectionsRcd> EcalDBCopy::ecalTimeBiasCorrectionsToken_
private

Definition at line 141 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalTimeCalibToken_

edm::ESGetToken<EcalTimeCalibConstants, EcalTimeCalibConstantsRcd> EcalDBCopy::ecalTimeCalibToken_
private

Definition at line 104 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalTimeOffsetConstantToken_

edm::ESGetToken<EcalTimeOffsetConstant, EcalTimeOffsetConstantRcd> EcalDBCopy::ecalTimeOffsetConstantToken_
private

Definition at line 137 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalTPGCrystalStatusToken_

edm::ESGetToken<EcalTPGCrystalStatus, EcalTPGCrystalStatusRcd> EcalDBCopy::ecalTPGCrystalStatusToken_
private

Definition at line 110 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalTPGTowerStatusToken_

edm::ESGetToken<EcalTPGTowerStatus, EcalTPGTowerStatusRcd> EcalDBCopy::ecalTPGTowerStatusToken_
private

Definition at line 111 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ ecalWeightXtalGroupsToken_

edm::ESGetToken<EcalWeightXtalGroups, EcalWeightXtalGroupsRcd> EcalDBCopy::ecalWeightXtalGroupsToken_
private

Definition at line 117 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ eeAlignmentToken_

edm::ESGetToken<Alignments, EEAlignmentRcd> EcalDBCopy::eeAlignmentToken_
private

Definition at line 135 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ esAlignmentToken_

edm::ESGetToken<Alignments, ESAlignmentRcd> EcalDBCopy::esAlignmentToken_
private

Definition at line 136 of file EcalDBCopy.h.

Referenced by copyToDB().

◆ m_cacheIDs

std::map<std::string, unsigned long long> EcalDBCopy::m_cacheIDs
private

Definition at line 100 of file EcalDBCopy.h.

Referenced by EcalDBCopy(), and shouldCopy().

◆ m_records

std::map<std::string, std::string> EcalDBCopy::m_records
private

Definition at line 101 of file EcalDBCopy.h.

Referenced by analyze(), copyToDB(), and EcalDBCopy().

◆ m_timetype

std::string EcalDBCopy::m_timetype
private

Definition at line 99 of file EcalDBCopy.h.