CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions
HcalNumberingScheme Class Reference

#include <HcalNumberingScheme.h>

Inheritance diagram for HcalNumberingScheme:
CaloNumberingScheme HcalTestNumberingScheme

Public Member Functions

virtual uint32_t getUnitID (const HcalNumberingFromDDD::HcalID &id)
 
 HcalNumberingScheme ()
 
virtual ~HcalNumberingScheme ()
 
- Public Member Functions inherited from CaloNumberingScheme
 CaloNumberingScheme (int iv=0)
 Constructor with optional verbosity control. More...
 
void setVerbosity (const int)
 Verbosity setting. More...
 
virtual ~CaloNumberingScheme ()
 

Additional Inherited Members

- Protected Attributes inherited from CaloNumberingScheme
int verbosity
 Verbosity field: Zero = quiet, increasing integers mean more output. More...
 

Detailed Description

Definition at line 13 of file HcalNumberingScheme.h.

Constructor & Destructor Documentation

HcalNumberingScheme::HcalNumberingScheme ( )

Definition at line 14 of file HcalNumberingScheme.cc.

14  : CaloNumberingScheme(0) {
15  edm::LogInfo("HcalSim") << "Creating HcalNumberingScheme";
16 }
CaloNumberingScheme(int iv=0)
Constructor with optional verbosity control.
HcalNumberingScheme::~HcalNumberingScheme ( )
virtual

Definition at line 18 of file HcalNumberingScheme.cc.

18  {
19  edm::LogInfo("HcalSim") << "Deleting HcalNumberingScheme";
20 }

Member Function Documentation

uint32_t HcalNumberingScheme::getUnitID ( const HcalNumberingFromDDD::HcalID id)
virtual

Reimplemented in HcalTestNumberingScheme.

Definition at line 22 of file HcalNumberingScheme.cc.

References TauDecayModes::dec, HLT_25ns14e33_v1_cff::depth, cmsHarvester::index, LogDebug, DetId::rawId(), and ecaldqm::zside().

Referenced by HCalSD::getHitFibreBundle(), HCalSD::getHitPMT(), FastHFShowerLibrary::recoHFShowerLibrary(), and HCalSD::setDetUnitId().

22  {
23 
24  int zside = 2*(id.zside) - 1;
25  int etaR = zside*(id.etaR);
26  HcalSubdetector subdet = (HcalSubdetector)(id.subdet);
27 
28  //pack it into an integer
29  // to be consistent with HcalDetId convention
30  uint32_t index = HcalDetId(subdet,etaR,id.phis,id.depth).rawId();
31 
32 #ifdef DebugLog
33  LogDebug("HcalSim") << "HcalNumberingScheme det = " << id.subdet
34  << " depth/lay = " << id.depth << "/" << id.lay
35  << " zside = " << id.zside << " eta/R = " << id.etaR
36  << " phi = " << id.phis << " oldphi = " << id.phi
37  << " packed index = 0x" << std::hex << index << std::dec;
38 #endif
39  return index;
40 
41 }
#define LogDebug(id)
int zside(DetId const &)
uint32_t rawId() const
get the raw id
Definition: DetId.h:43
HcalSubdetector
Definition: HcalAssistant.h:31