CondTools
SiStrip
plugins
SiStripSummaryReader.cc
Go to the documentation of this file.
1
#include "
CondFormats/SiStripObjects/interface/SiStripSummary.h
"
2
#include "
CondFormats/DataRecord/interface/SiStripSummaryRcd.h
"
3
4
#include "
CondTools/SiStrip/plugins/SiStripSummaryReader.h
"
5
6
#include <iostream>
7
#include <string>
8
#include <sstream>
9
#include <cstdio>
10
#include <sys/time.h>
11
12
SiStripSummaryReader::SiStripSummaryReader
(
const
edm::ParameterSet
& iConfig)
13
: printdebug_(iConfig.getUntrackedParameter<uint32_t>(
"printDebug"
, 1)) {}
14
15
SiStripSummaryReader::~SiStripSummaryReader
() {}
16
17
void
SiStripSummaryReader::analyze
(
const
edm::Event
&
e
,
const
edm::EventSetup
& iSetup) {
18
edm::ESHandle<SiStripSummary>
SiStripSummary_;
19
iSetup.
get
<
SiStripSummaryRcd
>().
get
(SiStripSummary_);
20
edm::LogInfo
(
"SiStripSummaryReader"
) <<
"[SiStripSummaryReader::analyze] End Reading SiStripSummary"
<< std::endl;
21
22
std::vector<uint32_t> detid = SiStripSummary_->
getDetIds
();
23
24
std::vector<std::string> userDB = SiStripSummary_->
getUserDBContent
();
25
std::stringstream
ss
;
26
for
(
size_t
i
= 0;
i
< userDB.size(); ++
i
)
27
ss
<< userDB[
i
] <<
" \n"
;
28
29
if
(
printdebug_
)
30
for
(
size_t
id
= 0;
id
< detid.size();
id
++) {
31
ss
<<
"\n\tdetid "
<< detid[
id
];
32
SiStripSummary::Range
range
= SiStripSummary_->
getRange
(detid[
id
]);
33
34
size_t
c
= 0;
35
for
(
SiStripSummary::ContainerIterator
it =
range
.first; it !=
range
.second; ++it) {
36
ss
<<
"\n\t\t "
<< userDB[
c
++] <<
" "
<< *it;
37
}
38
}
39
edm::LogInfo
(
"SiStripSummaryReader"
) <<
ss
.str();
40
}
FastTimerService_cff.range
range
Definition:
FastTimerService_cff.py:34
SiStripSummaryRcd.h
mps_fire.i
i
Definition:
mps_fire.py:355
edm::LogInfo
Definition:
MessageLogger.h:254
SiStripSummaryReader.h
SiStripSummary::getRange
const Range getRange(const uint32_t &detID) const
Definition:
SiStripSummary.cc:61
SiStripSummaryReader::SiStripSummaryReader
SiStripSummaryReader(const edm::ParameterSet &)
Definition:
SiStripSummaryReader.cc:12
contentValuesCheck.ss
ss
Definition:
contentValuesCheck.py:33
SiStripSummary::getDetIds
std::vector< uint32_t > getDetIds() const
Definition:
SiStripSummary.cc:70
edm::EventSetup::get
T get() const
Definition:
EventSetup.h:73
edm::ESHandle
Definition:
DTSurvey.h:22
SiStripSummary::Range
std::pair< ContainerIterator, ContainerIterator > Range
Definition:
SiStripSummary.h:83
SiStripSummaryRcd
Definition:
SiStripCondDataRecords.h:48
SiStripSummaryReader::~SiStripSummaryReader
~SiStripSummaryReader() override
Definition:
SiStripSummaryReader.cc:15
SiStripSummary::getUserDBContent
std::vector< std::string > getUserDBContent() const
Definition:
SiStripSummary.h:136
edm::ParameterSet
Definition:
ParameterSet.h:36
SiStripSummary::ContainerIterator
std::vector< float >::const_iterator ContainerIterator
Definition:
SiStripSummary.h:82
SiStripSummary.h
edm::EventSetup
Definition:
EventSetup.h:57
HltBtagPostValidation_cff.c
c
Definition:
HltBtagPostValidation_cff.py:31
SiStripSummaryReader::analyze
void analyze(const edm::Event &, const edm::EventSetup &) override
Definition:
SiStripSummaryReader.cc:17
get
#define get
SiStripSummaryReader::printdebug_
uint32_t printdebug_
Definition:
SiStripSummaryReader.h:25
triggerObjects_cff.id
id
Definition:
triggerObjects_cff.py:31
edm::Event
Definition:
Event.h:73
MillePedeFileConverter_cfg.e
e
Definition:
MillePedeFileConverter_cfg.py:37
Generated for CMSSW Reference Manual by
1.8.16