41 auto cc = setWhatProduced(
this);
43 auto apvGainLabels = iConfig.getParameter<std::vector<edm::ParameterSet> >(
"APVGain");
44 if (apvGainLabels.empty()) {
45 throw cms::Exception(
"Configuration") <<
"Got empty APVGain vector, but need at least one entry";
49 for (
const auto& gainPSet : apvGainLabels) {
51 tokenLabels_.emplace_back(
53 factor_.push_back_norm(gainPSet.getUntrackedParameter<
double>(
"NormalizationFactor", 1.));
56 factor_.resetIfBadNorm();
std::unique_ptr< SiStripGain > produce(const SiStripGainSimRcd &)
edm::ESGetToken< SiStripApvGain, SiStripApvGainSimRcd > token_
uint32_t cc[maxCellsPerHit]
~SiStripGainSimESProducer() override
std::vector< TokenLabel > tokenLabels_
TokenLabel(edm::ESConsumesCollector &cc, std::string record, std::string label)
std::pair< std::string, std::string > recordLabel_
SiStripDetInfo read(std::string filePath)
#define DEFINE_FWK_EVENTSETUP_MODULE(type)
SiStripGainFactor factor_
double get(const SiStripApvGain &gain, const int apvGainIndex) const
static constexpr char const *const kDefaultFile
ProductT const & get(ESGetToken< ProductT, DepRecordT > const &iToken) const
SiStripGainSimESProducer(const edm::ParameterSet &)