23 const uint32_t nLevels(baseNumber.
getLevels());
26 edm::LogInfo(
"MTDGeom") <<
"ETLNumberingScheme geometry levels = " << nLevels;
31 <<
"Not enough levels found in MTDBaseNumber ( " << nLevels <<
") Returning 0";
37 const bool preTDR = (baseNumber.
getLevelName(3).find(
"Ring") != std::string::npos);
44 int ringCopy(::atoi(baseName.data() + 4));
46 uint32_t discN, sectorS, sectorN;
48 discN = (baseNumber.
getLevelName(4).find(
"Disc1") != std::string::npos) ? 0 : 1;
49 sectorS = (baseNumber.
getLevelName(3).find(
"Front") != std::string::npos) ? 0 : 1;
53 ringCopy =
static_cast<int>(tmpId.
encodeSector(discN, sectorS, sectorN));
55 modtyp = (baseNumber.
getLevelName(2).find(
"_Left") != std::string::npos) ? 1 : 2;
60 const std::string_view& sideName(baseNumber.
getLevelName(nSide));
62 if (sideName.find(
"CALOECTSFront") != std::string::npos) {
66 const uint32_t
zside(sideCopy == 1 ? 1 : 0);
79 if ((modtyp != 0 && preTDR) || (modtyp == 0 && !preTDR)) {
81 <<
"****************** Bad module name = " << modtyp
87 (!preTDR && (1 > modCopy ||
90 <<
"****************** Bad module copy = " << modCopy
98 <<
"****************** Bad ring copy = " << ringCopy
106 const uint32_t intindex = thisETLdetid.rawId();
110 <<
" ring = " << ringCopy <<
" zside = " <<
zside <<
" module = " << modCopy
111 <<
" modtyp = " << modtyp <<
" Raw Id = " << intindex << thisETLdetid;
114 ETLDetId altETLdetid(
zside, discN, sectorS, sectorN, modCopy, modtyp);
115 const uint32_t altintindex = altETLdetid.rawId();
116 if (intindex != altintindex) {
118 <<
"disc = " << discN <<
" disc side = " << sectorS <<
" sector = " << sectorN <<
"\n" int getCopyNumber(int level) const
static constexpr int kETLv4maxModule
static constexpr int kETLv1maxModule
uint32_t encodeSector(uint32_t &disc, uint32_t &discside, uint32_t §or) const
std::string_view const & getLevelName(int level) const
static constexpr int kETLv1maxRing
Log< level::Info, false > LogInfo
Detector identifier class for the Endcap Timing Layer.
Log< level::Warning, false > LogWarning
static constexpr int kETLv5maxModule
static constexpr int kETLv4maxRing