CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
MuonSimHitNumberingScheme Class Reference

#include <MuonSimHitNumberingScheme.h>

Inheritance diagram for MuonSimHitNumberingScheme:
MuonNumberingScheme

Public Member Functions

int baseNumberToUnitNumber (const MuonBaseNumber &) const override
 
 MuonSimHitNumberingScheme (MuonSubDetector *, const MuonGeometryConstants &muonConstants)
 
 ~MuonSimHitNumberingScheme () override
 
- Public Member Functions inherited from MuonNumberingScheme
 MuonNumberingScheme ()
 
virtual ~MuonNumberingScheme ()
 

Private Attributes

MuonSubDetectortheDetector
 
MuonNumberingSchemetheNumbering
 

Detailed Description

wrapper class to handle numbering schemes for the different MuonSubDetector's

Author
Arno Straessner, CERN arno..nosp@m.stra.nosp@m.essne.nosp@m.r@ce.nosp@m.rn.ch

Definition at line 19 of file MuonSimHitNumberingScheme.h.

Constructor & Destructor Documentation

◆ MuonSimHitNumberingScheme()

MuonSimHitNumberingScheme::MuonSimHitNumberingScheme ( MuonSubDetector d,
const MuonGeometryConstants muonConstants 
)

Definition at line 11 of file MuonSimHitNumberingScheme.cc.

11  {
12  theDetector = d;
13  if (theDetector->isBarrel()) {
14  theNumbering = new DTNumberingScheme(muonConstants);
15  } else if (theDetector->isEndcap()) {
16  theNumbering = new CSCNumberingScheme(muonConstants);
17  } else if (theDetector->isRPC()) {
18  theNumbering = new RPCNumberingScheme(muonConstants);
19  } else if (theDetector->isGEM()) {
20  theNumbering = new GEMNumberingScheme(muonConstants);
21  } else if (theDetector->isME0()) {
22  theNumbering = new ME0NumberingScheme(muonConstants);
23  }
24 }

References ztail::d, MuonSubDetector::isBarrel(), MuonSubDetector::isEndcap(), MuonSubDetector::isGEM(), MuonSubDetector::isME0(), MuonSubDetector::isRPC(), theDetector, and theNumbering.

◆ ~MuonSimHitNumberingScheme()

MuonSimHitNumberingScheme::~MuonSimHitNumberingScheme ( )
override

Definition at line 26 of file MuonSimHitNumberingScheme.cc.

26 { delete theNumbering; }

References theNumbering.

Member Function Documentation

◆ baseNumberToUnitNumber()

int MuonSimHitNumberingScheme::baseNumberToUnitNumber ( const MuonBaseNumber num) const
overridevirtual

Reimplemented from MuonNumberingScheme.

Definition at line 28 of file MuonSimHitNumberingScheme.cc.

28  {
29  if (theNumbering) {
31  } else {
32  return 0;
33  }
34 }

References MuonNumberingScheme::baseNumberToUnitNumber(), EgammaValidation_cff::num, and theNumbering.

Referenced by MuonSensitiveDetector::setDetUnitId().

Member Data Documentation

◆ theDetector

MuonSubDetector* MuonSimHitNumberingScheme::theDetector
private

Definition at line 27 of file MuonSimHitNumberingScheme.h.

Referenced by MuonSimHitNumberingScheme().

◆ theNumbering

MuonNumberingScheme* MuonSimHitNumberingScheme::theNumbering
private
GEMNumberingScheme
Definition: GEMNumberingScheme.h:9
RPCNumberingScheme
Definition: RPCNumberingScheme.h:18
MuonSimHitNumberingScheme::theNumbering
MuonNumberingScheme * theNumbering
Definition: MuonSimHitNumberingScheme.h:28
MuonSubDetector::isBarrel
bool isBarrel()
Definition: MuonSubDetector.cc:21
MuonNumberingScheme::baseNumberToUnitNumber
virtual int baseNumberToUnitNumber(const MuonBaseNumber &) const
Definition: MuonNumberingScheme.cc:4
MuonSubDetector::isME0
bool isME0()
Definition: MuonSubDetector.cc:29
MuonSimHitNumberingScheme::theDetector
MuonSubDetector * theDetector
Definition: MuonSimHitNumberingScheme.h:27
MuonSubDetector::isEndcap
bool isEndcap()
Definition: MuonSubDetector.cc:23
MuonSubDetector::isRPC
bool isRPC()
Definition: MuonSubDetector.cc:25
EgammaValidation_cff.num
num
Definition: EgammaValidation_cff.py:34
ME0NumberingScheme
Definition: ME0NumberingScheme.h:9
MuonSubDetector::isGEM
bool isGEM()
Definition: MuonSubDetector.cc:27
CSCNumberingScheme
Definition: CSCNumberingScheme.h:18
ztail.d
d
Definition: ztail.py:151
DTNumberingScheme
Definition: DTNumberingScheme.h:20