|
|
Go to the documentation of this file.
21 : printdebug_(iConfig.getUntrackedParameter<
bool>(
"printDebug",
false)), tkGeomToken_(esConsumes()) {}
27 edm::LogInfo(
"SiStripDetVOffFakeBuilder") <<
" There are " << tkGeom.detUnits().size() <<
" detectors" << std::endl;
29 for (
const auto& it : tkGeom.detUnits()) {
30 if (dynamic_cast<StripGeomDetUnit const*>(it) !=
nullptr) {
31 uint32_t detid = (it->geographicalId()).rawId();
32 const StripTopology&
p = dynamic_cast<StripGeomDetUnit const*>(it)->specificTopology();
33 unsigned short Nstrips =
p.nstrips();
34 if (Nstrips < 1 || Nstrips > 768) {
36 <<
" Problem with Number of strips in detector.. " <<
p.nstrips() <<
" Exiting program" << endl;
41 edm::LogInfo(
"SiStripDetVOffFakeBuilder") <<
"detid " << detid;
52 <<
"... creating dummy SiStripDetVOff Data for Run " <<
run <<
"\n " << std::endl;
58 for (std::vector<uint32_t>::const_iterator it =
detids.begin(); it !=
detids.end(); it++) {
63 edm::LogInfo(
"SiStripDetVOffFakeBuilder") <<
"detid: " << *it <<
" HV\t OFF" << std::endl;
64 SiStripDetVOff_->
put(*it, 1, -1);
68 edm::LogInfo(
"SiStripDetVOffFakeBuilder") <<
"detid: " << *it <<
" LV\t OFF" << std::endl;
69 SiStripDetVOff_->
put(*it, -1, 1);
72 if (lv <= 2 || hv <= 2)
73 edm::LogInfo(
"SiStripDetVOffFakeBuilder") <<
"detid: " << *it <<
" V\t OFF" << std::endl;
92 edm::LogError(
"SiStripDetVOffFakeBuilder") <<
"caught std::exception " << er.what() << std::endl;
95 edm::LogError(
"SiStripDetVOffFakeBuilder") <<
"Service is unavailable" << std::endl;
cond::Time_t beginOfTime() const
void appendSinceTime(const T *payloadObj, cond::Time_t sinceTime, const std::string &recordName)
Log< level::Info, false > LogInfo
char const * what() const noexcept override
void analyze(const edm::Event &, const edm::EventSetup &) override
void createNewIOV(const T *firstPayloadObj, cond::Time_t firstSinceTime, cond::Time_t, const std::string &recordName)
edm::ESGetToken< TrackerGeometry, TrackerDigiGeometryRecord > tkGeomToken_
SiStripDetVOffFakeBuilder(const edm::ParameterSet &iConfig)
virtual void initialize(const edm::EventSetup &)
std::vector< uint32_t > detids
bool put(const uint32_t DetId, const int HVoff, const int LVoff)
Insert information for a single detId.
Base exception class for the object to relational access.
Log< level::Error, false > LogError
bool getData(T &iHolder) const
cond::Time_t endOfTime() const
bool isNewTagRequest(const std::string &recordName)
~SiStripDetVOffFakeBuilder() override
cond::Time_t currentTime() const
Namespace of DDCMS conversion namespace.