11 bool true_for_positive_eta,
16 id_ |= ( true_for_positive_eta << 8 ) | ( sector << 4 ) |
module;
20 bool true_for_positive_eta,
25 buildMe( section, true_for_positive_eta, sector, module ) ;
43 throw cms::Exception(
"Invalid DetId") <<
"Cannot initialize CASTORDetId from " << std::hex << gen.
rawId() << std::dec;
55 throw cms::Exception(
"Invalid DetId") <<
"Cannot assign Castor DetId from " << std::hex << gen.
rawId() << std::dec;
82 if( mod > 2 && mod <= 14 )
107 return ( 0 < iSector &&
123 s <<
"(CASTOR" << ((
id.zside()==1)?(
"+"):(
"-"));
125 switch (
id.section())
129 default : s <<
" UNKNOWN ";
132 return s <<
id.sector() <<
',' <<
id.module() <<
',' <<
')';
static bool validDetId(Section iSection, bool posEta, int iSector, int iMod)
int sector() const
get the sector (1-16)
void buildMe(Section section, bool true_for_positive_eta, int sector, int module)
int module() const
get the module (1-2 for EM, 1-12 for HAD)
uint32_t denseIndex() const
std::ostream & operator<<(std::ostream &out, const ALILine &li)
Section section() const
get the section
uint32_t rawId() const
get the raw id
static HcalCastorDetId detIdFromDenseIndex(uint32_t di)
int zside() const
get the z-side of the cell (1/-1)
int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum) ...
static const int SubdetectorId
HcalCastorDetId & operator=(const DetId &id)
bool null() const
is this a null id ?
Detector det() const
get the detector field from this detid
T mod(const T &a, const T &b)