#include <CaloGenericDetId.h>
Public Member Functions | |
CaloGenericDetId (uint32_t rawid) | |
CaloGenericDetId (const DetId &id) | |
CaloGenericDetId (DetId::Detector iDet, int iSub, uint32_t iDenseIndex) | |
uint32_t | denseIndex () const |
bool | isCalo () const |
bool | isCaloTower () const |
bool | isCastor () const |
bool | isEB () const |
bool | isEcal () const |
bool | isEE () const |
bool | isES () const |
bool | isHB () const |
bool | isHcal () const |
bool | isHE () const |
bool | isHF () const |
bool | isHO () const |
bool | isZDC () const |
uint32_t | sizeForDenseIndexing () const |
bool | validDetId () const |
Definition at line 13 of file CaloGenericDetId.h.
CaloGenericDetId::CaloGenericDetId | ( | uint32_t | rawid | ) | [inline] |
Definition at line 17 of file CaloGenericDetId.h.
: DetId( rawid ) {}
CaloGenericDetId::CaloGenericDetId | ( | const DetId & | id | ) | [inline] |
Definition at line 19 of file CaloGenericDetId.h.
: DetId ( id ) {}
CaloGenericDetId::CaloGenericDetId | ( | DetId::Detector | iDet, |
int | iSub, | ||
uint32_t | iDenseIndex | ||
) |
Definition at line 4 of file CaloGenericDetId.cc.
References HcalDetId::detIdFromDenseIndex(), CaloTowerDetId::detIdFromDenseIndex(), ESDetId::detIdFromDenseIndex(), HcalCastorDetId::detIdFromDenseIndex(), EBDetId::detIdFromDenseIndex(), EEDetId::detIdFromDenseIndex(), HcalZDCDetId::detIdFromDenseIndex(), DetId::id_, isCaloTower(), isCastor(), isEB(), isEE(), isES(), isHcal(), isZDC(), and DetId::rawId().
: DetId( iDet, iSub ) { id_ = ( isEB() ? EBDetId::detIdFromDenseIndex( iDin ).rawId() : ( isEE() ? EEDetId::detIdFromDenseIndex( iDin ).rawId() : ( isES() ? ESDetId::detIdFromDenseIndex( iDin ).rawId() : ( isHcal() ? HcalDetId::detIdFromDenseIndex( iDin ).rawId() : ( isZDC() ? HcalZDCDetId::detIdFromDenseIndex( iDin ).rawId() : ( isCastor() ? HcalCastorDetId::detIdFromDenseIndex( iDin ).rawId() : ( isCaloTower() ? CaloTowerDetId::detIdFromDenseIndex( iDin ).rawId() : 0 ) ) ) ) ) ) ) ; }
uint32_t CaloGenericDetId::denseIndex | ( | ) | const |
Definition at line 18 of file CaloGenericDetId.cc.
References isCaloTower(), isCastor(), isEB(), isEE(), isES(), isHcal(), isZDC(), and DetId::rawId().
Referenced by CaloSubdetectorGeometry::deltaEta(), CaloSubdetectorGeometry::deltaPhi(), CaloTowerGeometry::newCell(), ZdcGeometry::newCell(), HcalDDDGeometry::newCell(), HcalGeometry::newCell(), and CastorGeometry::newCell().
{ return ( isEB() ? EBDetId( rawId() ).denseIndex() : ( isEE() ? EEDetId( rawId() ).denseIndex() : ( isES() ? ESDetId( rawId() ).denseIndex() : ( isHcal() ? HcalDetId( rawId() ).denseIndex() : ( isZDC() ? HcalZDCDetId( rawId() ).denseIndex() : ( isCastor() ? HcalCastorDetId( rawId() ).denseIndex() : ( isCaloTower() ? CaloTowerDetId( rawId() ).denseIndex() : ~0 ) ) ) ) ) ) ) ; }
bool CaloGenericDetId::isCalo | ( | ) | const [inline] |
Definition at line 40 of file CaloGenericDetId.h.
References DetId::Calo, and DetId::det().
Referenced by isCaloTower(), isCastor(), and isZDC().
{ return det() == DetId::Calo ; }
bool CaloGenericDetId::isCaloTower | ( | ) | const [inline] |
Definition at line 43 of file CaloGenericDetId.h.
References isCalo(), CaloTowerDetId::SubdetId, and DetId::subdetId().
Referenced by CaloTowerGeometry::alignmentTransformIndexLocal(), CaloGenericDetId(), denseIndex(), CaloTowerGeometry::newCell(), sizeForDenseIndexing(), and validDetId().
{ return isCalo() && subdetId() == CaloTowerDetId::SubdetId ; }
bool CaloGenericDetId::isCastor | ( | ) | const [inline] |
Definition at line 42 of file CaloGenericDetId.h.
References isCalo(), HcalCastorDetId::SubdetectorId, and DetId::subdetId().
Referenced by CastorGeometry::alignmentTransformIndexLocal(), CaloGenericDetId(), denseIndex(), CastorGeometry::newCell(), sizeForDenseIndexing(), and validDetId().
{ return isCalo() && subdetId() == HcalCastorDetId::SubdetectorId ; }
bool CaloGenericDetId::isEB | ( | ) | const [inline] |
Definition at line 32 of file CaloGenericDetId.h.
References isEcal(), EBDetId::Subdet, and DetId::subdetId().
Referenced by EcalBarrelGeometry::alignmentTransformIndexLocal(), CaloGenericDetId(), denseIndex(), sizeForDenseIndexing(), and validDetId().
{ return isEcal() && subdetId() == EBDetId::Subdet ; }
bool CaloGenericDetId::isEcal | ( | ) | const [inline] |
Definition at line 31 of file CaloGenericDetId.h.
References DetId::det(), and DetId::Ecal.
Referenced by isEB(), isEE(), and isES().
{ return det() == DetId::Ecal ; }
bool CaloGenericDetId::isEE | ( | ) | const [inline] |
Definition at line 33 of file CaloGenericDetId.h.
References isEcal(), EEDetId::Subdet, and DetId::subdetId().
Referenced by EcalEndcapGeometry::alignmentTransformIndexLocal(), CaloGenericDetId(), denseIndex(), sizeForDenseIndexing(), and validDetId().
{ return isEcal() && subdetId() == EEDetId::Subdet ; }
bool CaloGenericDetId::isES | ( | ) | const [inline] |
Definition at line 34 of file CaloGenericDetId.h.
References isEcal(), ESDetId::Subdet, and DetId::subdetId().
Referenced by EcalPreshowerGeometry::alignmentTransformIndexLocal(), CaloGenericDetId(), denseIndex(), sizeForDenseIndexing(), and validDetId().
{ return isEcal() && subdetId() == ESDetId::Subdet ; }
bool CaloGenericDetId::isHB | ( | ) | const [inline] |
Definition at line 36 of file CaloGenericDetId.h.
References HcalBarrel, isHcal(), and DetId::subdetId().
Referenced by HcalGeometry::alignmentTransformIndexLocal(), HcalDDDGeometry::newCell(), and HcalGeometry::newCell().
{ return isHcal() && subdetId() == HcalBarrel ; }
bool CaloGenericDetId::isHcal | ( | ) | const [inline] |
Definition at line 35 of file CaloGenericDetId.h.
References DetId::det(), and DetId::Hcal.
Referenced by HcalGeometry::alignmentTransformIndexLocal(), CaloGenericDetId(), denseIndex(), isHB(), isHE(), isHF(), isHO(), HcalDDDGeometry::newCell(), HcalGeometry::newCell(), sizeForDenseIndexing(), and validDetId().
{ return det() == DetId::Hcal ; }
bool CaloGenericDetId::isHE | ( | ) | const [inline] |
Definition at line 37 of file CaloGenericDetId.h.
References HcalEndcap, isHcal(), and DetId::subdetId().
Referenced by HcalGeometry::alignmentTransformIndexLocal(), HcalDDDGeometry::newCell(), and HcalGeometry::newCell().
{ return isHcal() && subdetId() == HcalEndcap ; }
bool CaloGenericDetId::isHF | ( | ) | const [inline] |
Definition at line 39 of file CaloGenericDetId.h.
References HcalForward, isHcal(), and DetId::subdetId().
Referenced by HcalGeometry::alignmentTransformIndexLocal(), and HcalGeometry::localCorners().
{ return isHcal() && subdetId() == HcalForward ; }
bool CaloGenericDetId::isHO | ( | ) | const [inline] |
Definition at line 38 of file CaloGenericDetId.h.
References HcalOuter, isHcal(), and DetId::subdetId().
Referenced by HcalGeometry::alignmentTransformIndexLocal(), HcalDDDGeometry::newCell(), and HcalGeometry::newCell().
bool CaloGenericDetId::isZDC | ( | ) | const [inline] |
Definition at line 41 of file CaloGenericDetId.h.
References isCalo(), HcalZDCDetId::SubdetectorId, and DetId::subdetId().
Referenced by ZdcGeometry::alignmentTransformIndexLocal(), CaloGenericDetId(), denseIndex(), ZdcGeometry::newCell(), sizeForDenseIndexing(), and validDetId().
{ return isCalo() && subdetId() == HcalZDCDetId::SubdetectorId ; }
uint32_t CaloGenericDetId::sizeForDenseIndexing | ( | ) | const |
Definition at line 30 of file CaloGenericDetId.cc.
References isCaloTower(), isCastor(), isEB(), isEE(), isES(), isHcal(), isZDC(), EBDetId::kSizeForDenseIndexing, ESDetId::kSizeForDenseIndexing, HcalDetId::kSizeForDenseIndexing, CaloTowerDetId::kSizeForDenseIndexing, HcalCastorDetId::kSizeForDenseIndexing, EEDetId::kSizeForDenseIndexing, and HcalZDCDetId::kSizeForDenseIndexing.
Referenced by CaloSubdetectorGeometry::deltaEta(), and CaloSubdetectorGeometry::deltaPhi().
{ return ( isEB() ? EBDetId::kSizeForDenseIndexing : ( isEE() ? EEDetId::kSizeForDenseIndexing : ( isES() ? ESDetId::kSizeForDenseIndexing : ( isHcal() ? HcalDetId::kSizeForDenseIndexing : ( isZDC() ? HcalZDCDetId::kSizeForDenseIndexing : ( isCastor() ? HcalCastorDetId::kSizeForDenseIndexing : ( isCaloTower() ? CaloTowerDetId::kSizeForDenseIndexing : 0 ) ) ) ) ) ) ) ; }
bool CaloGenericDetId::validDetId | ( | ) | const |
Definition at line 42 of file CaloGenericDetId.cc.
References HcalZDCDetId::channel(), HcalDetId::depth(), EBDetId::ieta(), CaloTowerDetId::ieta(), HcalDetId::ieta(), HcalDetId::iphi(), EBDetId::iphi(), CaloTowerDetId::iphi(), isCaloTower(), isCastor(), isEB(), isEE(), isES(), isHcal(), isZDC(), EEDetId::ix(), EEDetId::iy(), HcalCastorDetId::module(), ESDetId::plane(), DetId::rawId(), HcalCastorDetId::section(), HcalZDCDetId::section(), HcalCastorDetId::sector(), ESDetId::six(), ESDetId::siy(), ESDetId::strip(), HcalDetId::subdet(), ESDetId::zside(), HcalCastorDetId::zside(), and EEDetId::zside().
{ bool returnValue ( false ) ; if( isEB() ) { const EBDetId ebid ( rawId() ) ; returnValue = EBDetId::validDetId( ebid.ieta(), ebid.iphi() ) ; } else { if( isEE() ) { const EEDetId eeid ( rawId() ) ; returnValue = EEDetId::validDetId( eeid.ix(), eeid.iy(), eeid.zside() ) ; } else { if( isES() ) { const ESDetId esid ( rawId() ) ; returnValue = ESDetId::validDetId( esid.strip(), esid.six(), esid.siy(), esid.plane(), esid.zside() ) ; } else { if( isHcal() ) { const HcalDetId hcid ( rawId() ) ; returnValue = HcalDetId::validDetId( hcid.subdet(), hcid.ieta() , hcid.iphi() , hcid.depth() ) ; } else { if( isZDC() ) { const HcalZDCDetId zdid ( rawId() ) ; returnValue = HcalZDCDetId::validDetId( zdid.section(), zdid.channel() ) ; } else { if( isCastor() ) { const HcalCastorDetId zdid ( rawId() ) ; returnValue = HcalCastorDetId::validDetId( zdid.section(), zdid.zside()>0, zdid.sector(), zdid.module() ) ; } else { if( isCaloTower() ) { const CaloTowerDetId ctid ( rawId() ) ; returnValue = CaloTowerDetId::validDetId( ctid.ieta(), ctid.iphi() ) ; } } } } } } } return returnValue ; }