CMS 3D CMS Logo

HcalMahiPulseOffsetsGPUESProducer.cc
Go to the documentation of this file.
1 #include <array>
2 #include <iostream>
3 #include <tuple>
4 #include <utility>
5 
19 
21 public:
23  ~HcalMahiPulseOffsetsGPUESProducer() override = default;
24 
26  std::unique_ptr<HcalMahiPulseOffsetsGPU> produce(JobConfigurationGPURecord const&);
27 
28 protected:
30  const edm::IOVSyncValue&,
31  edm::ValidityInterval&) override;
32 
33 private:
34  std::vector<int> pulseOffsets_;
35 };
36 
38  : pulseOffsets_(pset.getParameter<std::vector<int>>("pulseOffsets")) {
39  setWhatProduced(this);
40  findingRecord<JobConfigurationGPURecord>();
41 }
42 
44  const edm::IOVSyncValue& iTime,
45  edm::ValidityInterval& oInterval) {
47 }
48 
51  d.add<std::vector<int>>("pulseOffsets", {-3, -2, -1, 0, 1, 2, 3, 4});
52  desc.addWithDefaultLabel(d);
53 }
54 
55 std::unique_ptr<HcalMahiPulseOffsetsGPU> HcalMahiPulseOffsetsGPUESProducer::produce(JobConfigurationGPURecord const&) {
56  return std::make_unique<HcalMahiPulseOffsetsGPU>(pulseOffsets_);
57 }
58 
auto setWhatProduced(T *iThis, const es::Label &iLabel={})
Definition: ESProducer.h:166
static const IOVSyncValue & endOfTime()
Definition: IOVSyncValue.cc:82
void setIntervalFor(const edm::eventsetup::EventSetupRecordKey &, const edm::IOVSyncValue &, edm::ValidityInterval &) override
std::pair< Time_t, Time_t > ValidityInterval
Definition: Time.h:17
HcalMahiPulseOffsetsGPUESProducer(edm::ParameterSet const &)
std::unique_ptr< HcalMahiPulseOffsetsGPU > produce(JobConfigurationGPURecord const &)
static const IOVSyncValue & beginOfTime()
Definition: IOVSyncValue.cc:88
~HcalMahiPulseOffsetsGPUESProducer() override=default
d
Definition: ztail.py:151
#define DEFINE_FWK_EVENTSETUP_SOURCE(type)
Definition: SourceFactory.h:92
static void fillDescriptions(edm::ConfigurationDescriptions &)