CMS 3D CMS Logo

DIPLumiProducer.h
Go to the documentation of this file.
1 #ifndef RecoLuminosity_LumiProducer_DIPLumiProducer_h
2 #define RecoLuminosity_LumiProducer_DIPLumiProducer_h
3 
9 #include <memory>
10 namespace edm {
11  class IOVSyncValue;
12 }
13 namespace coral {
14  class ISchema;
15 }
16 class DIPLuminosityRcd;
17 class DIPLumiSummary;
18 class DIPLumiDetail;
23 public:
25  typedef std::shared_ptr<const DIPLumiSummary> ReturnSummaryType;
27  typedef std::shared_ptr<const DIPLumiDetail> ReturnDetailType;
29  ~DIPLumiProducer() override;
30 
31 protected:
33  const edm::IOVSyncValue&,
34  edm::ValidityInterval&) override;
35 
36 private:
37  unsigned int maxavailableLSforRun(coral::ISchema& schema, const std::string& tablename, unsigned int runnumber);
38 
39 private:
41  std::map<unsigned int, std::shared_ptr<const DIPLumiSummary> > m_summarycache;
42  std::map<unsigned int, std::shared_ptr<const DIPLumiDetail> > m_detailcache;
43  bool m_isNullRun; //if lumi data exist for this run
44  unsigned int m_summarycachedrun;
45  unsigned int m_detailcachedrun;
46  unsigned int m_cachesize;
47  std::shared_ptr<const DIPLumiSummary> m_summaryresult;
48  std::shared_ptr<const DIPLumiDetail> m_detailresult;
50 
51 private:
52  void fillsummarycache(unsigned int runnumber, unsigned int startlsnum);
53  void filldetailcache(unsigned int runnumber, unsigned int startlsnum);
54 };
55 #endif
DIPLumiProducer::m_detailcachedrun
unsigned int m_detailcachedrun
Definition: DIPLumiProducer.h:45
DIPLumiProducer::m_connectStr
std::string m_connectStr
Definition: DIPLumiProducer.h:40
DIPLumiProducer::m_pcurrentTime
const edm::IOVSyncValue * m_pcurrentTime
Definition: DIPLumiProducer.h:49
ESHandle.h
DIPLumiProducer::maxavailableLSforRun
unsigned int maxavailableLSforRun(coral::ISchema &schema, const std::string &tablename, unsigned int runnumber)
Definition: DIPLumiProducer.cc:238
DIPLumiProducer::m_detailcache
std::map< unsigned int, std::shared_ptr< const DIPLumiDetail > > m_detailcache
Definition: DIPLumiProducer.h:42
edm
HLT enums.
Definition: AlignableModifier.h:19
DIPLumiProducer::setIntervalFor
void setIntervalFor(const edm::eventsetup::EventSetupRecordKey &, const edm::IOVSyncValue &, edm::ValidityInterval &) override
Definition: DIPLumiProducer.cc:136
DIPLumiProducer::m_detailresult
std::shared_ptr< const DIPLumiDetail > m_detailresult
Definition: DIPLumiProducer.h:48
DIPLumiProducer::ReturnDetailType
std::shared_ptr< const DIPLumiDetail > ReturnDetailType
Definition: DIPLumiProducer.h:27
edm::ValidityInterval
Definition: ValidityInterval.h:28
ESProducer.h
edm::EventSetupRecordIntervalFinder
Definition: EventSetupRecordIntervalFinder.h:33
DIPLumiProducer
Definition: DIPLumiProducer.h:22
edm::eventsetup::EventSetupRecordKey
Definition: EventSetupRecordKey.h:30
DIPLumiProducer::fillsummarycache
void fillsummarycache(unsigned int runnumber, unsigned int startlsnum)
Definition: DIPLumiProducer.cc:144
DIPLumiSummary
Definition: DIPLumiSummary.h:7
coral
Definition: Binary.h:9
DIPLumiProducer::m_summarycachedrun
unsigned int m_summarycachedrun
Definition: DIPLumiProducer.h:44
IOVSyncValue
DIPLumiProducer::filldetailcache
void filldetailcache(unsigned int runnumber, unsigned int startlsnum)
Definition: DIPLumiProducer.cc:265
DIPLuminosityRcd
Definition: DIPLuminosityRcd.h:5
edm::IOVSyncValue
Definition: IOVSyncValue.h:31
EventSetupRecordIntervalFinder.h
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
edm::ParameterSet
Definition: ParameterSet.h:36
cond::runnumber
Definition: Time.h:19
DIPLumiProducer::DIPLumiProducer
DIPLumiProducer(const edm::ParameterSet &)
Definition: DIPLumiProducer.cc:62
DIPLumiProducer::produceDetail
ReturnDetailType produceDetail(const DIPLuminosityRcd &)
Definition: DIPLumiProducer.cc:103
DIPLumiProducer::~DIPLumiProducer
~DIPLumiProducer() override
Definition: DIPLumiProducer.cc:345
ModuleFactory.h
DIPLumiProducer::m_isNullRun
bool m_isNullRun
Definition: DIPLumiProducer.h:43
DIPLumiDetail
Definition: DIPLumiDetail.h:7
DIPLumiProducer::m_cachesize
unsigned int m_cachesize
Definition: DIPLumiProducer.h:46
DIPLumiProducer::m_summaryresult
std::shared_ptr< const DIPLumiSummary > m_summaryresult
Definition: DIPLumiProducer.h:47
DIPLumiProducer::m_summarycache
std::map< unsigned int, std::shared_ptr< const DIPLumiSummary > > m_summarycache
Definition: DIPLumiProducer.h:41
DIPLumiProducer::ReturnSummaryType
std::shared_ptr< const DIPLumiSummary > ReturnSummaryType
Definition: DIPLumiProducer.h:25
DIPLumiProducer::produceSummary
ReturnSummaryType produceSummary(const DIPLuminosityRcd &)
Definition: DIPLumiProducer.cc:71
edm::ESProducer
Definition: ESProducer.h:101
ParameterSet.h