ATLAS Offline Software
Public Types | Public Member Functions | Static Public Attributes | Protected Member Functions | Protected Attributes | Private Attributes | List of all members
MuonTGC_Cabling::TGCId Class Reference

#include <TGCId.h>

Inheritance diagram for MuonTGC_Cabling::TGCId:
Collaboration diagram for MuonTGC_Cabling::TGCId:

Public Types

enum  IdType { IdType::NoIdType, IdType::Channel, IdType::Module, IdType::MaxIdType }
 
enum  SideType { NoSideType =-1, Aside, Cside, MaxSideType }
 
enum  ModuleType {
  NoModuleType =-1, WD, SD, WT,
  ST, WI, SI, MaxModuleType
}
 
enum  SignalType { NoSignalType =-1, Wire, Strip, MaxSignalType }
 
enum  MultipletType {
  NoMultipletType =-1, Doublet, Triplet, Inner,
  MaxChamberType
}
 
enum  RegionType { NoRegionType =-1, Endcap, Forward, MaxRegionType }
 

Public Member Functions

 TGCId (IdType vtype=IdType::NoIdType)
 
virtual ~TGCId ()=default
 
virtual bool isValid () const
 
IdType getIdType (void) const
 
SideType getSideType (void) const
 
ModuleType getModuleType (void) const
 
SignalType getSignalType (void) const
 
MultipletType getMultipletType (void) const
 
RegionType getRegionType (void) const
 
int getSectorInReadout (void) const
 
virtual int getSectorInOctant () const
 
virtual int getSectorModule () const
 
int getStation () const
 
int getOctant () const
 
virtual int getSector () const
 
int getChamber () const
 
int getId () const
 
int getBlock () const
 
bool isAside () const
 
bool isCside () const
 
bool isStrip () const
 
bool isWire () const
 
bool isTriplet () const
 
bool isDoublet () const
 
bool isInner () const
 
bool isForward () const
 
bool isEndcap () const
 
bool isBackward () const
 
void setSideType (SideType side)
 
void setModuleType (ModuleType module)
 
void setSignalType (SignalType signal)
 
void setMultipletType (MultipletType multiplet)
 
void setRegionType (RegionType region)
 
virtual void setStation (int vstation)
 
virtual void setOctant (int voctant)
 
virtual void setSector (int vsector)
 
virtual void setChamber (int chamber)
 
void setId (int id)
 

Static Public Attributes

static constexpr int NUM_STATIONS = 4
 in ChannelId More...
 
static constexpr int NUM_LAYERS = 9
 
static constexpr int NUM_OCTANT = 8
 
static constexpr int NUM_ENDCAP_SECTOR = 48
 
static constexpr int NUM_FORWARD_SECTOR = 24
 
static constexpr int NUM_INNER_SECTOR = 24
 
static constexpr int N_RODS = 12
 

Protected Member Functions

void setIdType (IdType idtype)
 
void setReadoutSector (int sector)
 
void setSectorModule (int sectorModule)
 

Protected Attributes

SideType m_side {NoSideType}
 
ModuleType m_module {NoModuleType}
 
SignalType m_signal {NoSignalType}
 
MultipletType m_multiplet {NoMultipletType}
 
RegionType m_region {NoRegionType}
 
int m_station {-1}
 
int m_octant {-1}
 
int m_sector {-1}
 
int m_chamber {-1}
 
int m_id {-1}
 

Private Attributes

IdType m_idType {IdType::NoIdType}
 

Detailed Description

Definition at line 10 of file TGCId.h.

Member Enumeration Documentation

◆ IdType

Enumerator
NoIdType 
Channel 
Module 
MaxIdType 

Definition at line 12 of file TGCId.h.

12 { NoIdType, Channel, Module, MaxIdType };

◆ ModuleType

Enumerator
NoModuleType 
WD 
SD 
WT 
ST 
WI 
SI 
MaxModuleType 

Definition at line 47 of file TGCId.h.

47  {NoModuleType=-1, WD,SD,WT,ST,WI,SI,

◆ MultipletType

Enumerator
NoMultipletType 
Doublet 
Triplet 
Inner 
MaxChamberType 

Definition at line 51 of file TGCId.h.

◆ RegionType

Enumerator
NoRegionType 
Endcap 
Forward 
MaxRegionType 

Definition at line 53 of file TGCId.h.

◆ SideType

Enumerator
NoSideType 
Aside 
Cside 
MaxSideType 

Definition at line 45 of file TGCId.h.

45  {NoSideType=-1, Aside,Cside,
46  MaxSideType};

◆ SignalType

Enumerator
NoSignalType 
Wire 
Strip 
MaxSignalType 

Definition at line 49 of file TGCId.h.

49  {NoSignalType=-1, Wire,Strip,

Constructor & Destructor Documentation

◆ TGCId()

MuonTGC_Cabling::TGCId::TGCId ( TGCId::IdType  vtype = IdType::NoIdType)

Definition at line 9 of file TGCId.cxx.

9  {
10  m_idType = vtype;
11 }

◆ ~TGCId()

virtual MuonTGC_Cabling::TGCId::~TGCId ( )
virtualdefault

Member Function Documentation

◆ getBlock()

int MuonTGC_Cabling::TGCId::getBlock ( ) const

◆ getChamber()

int MuonTGC_Cabling::TGCId::getChamber ( ) const
inline

Definition at line 131 of file TGCId.h.

131 { return m_chamber; }

◆ getId()

int MuonTGC_Cabling::TGCId::getId ( ) const
inline

Definition at line 132 of file TGCId.h.

132 { return m_id; }

◆ getIdType()

TGCId::IdType MuonTGC_Cabling::TGCId::getIdType ( void  ) const
inline

Definition at line 121 of file TGCId.h.

121 { return m_idType; }

◆ getModuleType()

TGCId::ModuleType MuonTGC_Cabling::TGCId::getModuleType ( void  ) const
inline

Definition at line 123 of file TGCId.h.

123 { return m_module; }

◆ getMultipletType()

TGCId::MultipletType MuonTGC_Cabling::TGCId::getMultipletType ( void  ) const
inline

Definition at line 125 of file TGCId.h.

125 { return m_multiplet; }

◆ getOctant()

int MuonTGC_Cabling::TGCId::getOctant ( ) const
inline

Definition at line 129 of file TGCId.h.

129 { return m_octant; }

◆ getRegionType()

TGCId::RegionType MuonTGC_Cabling::TGCId::getRegionType ( void  ) const
inline

Definition at line 126 of file TGCId.h.

126 { return m_region; }

◆ getSector()

int MuonTGC_Cabling::TGCId::getSector ( ) const
inlinevirtual

Reimplemented in MuonTGC_Cabling::TGCChannelASDIn.

Definition at line 130 of file TGCId.h.

130 { return m_sector; }

◆ getSectorInOctant()

int MuonTGC_Cabling::TGCId::getSectorInOctant ( ) const
virtual

Definition at line 13 of file TGCId.cxx.

13  {
14  if(isInner()){
16  }
17  if(isEndcap()){
19  }
20  if(isForward()){
22  }
23  return -1;
24 }

◆ getSectorInReadout()

int MuonTGC_Cabling::TGCId::getSectorInReadout ( void  ) const

Definition at line 26 of file TGCId.cxx.

26  {
27  if(isInner()){
28  return getSector() % (NUM_INNER_SECTOR/N_RODS);
29  }
30  if(isEndcap()){
31  return getSector() % (NUM_ENDCAP_SECTOR/N_RODS);
32  }
33  if(isForward()){
34  return getSector() % (NUM_FORWARD_SECTOR/N_RODS);
35  }
36  return -1;
37 }

◆ getSectorModule()

int MuonTGC_Cabling::TGCId::getSectorModule ( ) const
virtual

Definition at line 139 of file TGCId.cxx.

139  {
140  if(m_sector==-1) return -1;
141 
142  static const int moduleEndcap[6]={ 0, 1, 3, 4, 6, 7};
143  static const int moduleForward[3]={ 2, 5, 8};
144  static const int moduleEI[3]={ 9, 10, 11};
145  static const int moduleFI[3]={ 12, 13, 14};
146 
147  if(isEndcap()){
148  if(isInner()) return moduleEI[getSectorInOctant()];
149  return moduleEndcap[getSectorInOctant()];
150  }
151  if(isForward()){
152  if(isInner()) return moduleFI[getSectorInOctant()];
153  return moduleForward[getSectorInOctant()];
154  }
155  return -1;
156 }

◆ getSideType()

TGCId::SideType MuonTGC_Cabling::TGCId::getSideType ( void  ) const
inline

Definition at line 122 of file TGCId.h.

122 { return m_side; }

◆ getSignalType()

TGCId::SignalType MuonTGC_Cabling::TGCId::getSignalType ( void  ) const
inline

Definition at line 124 of file TGCId.h.

124 { return m_signal; }

◆ getStation()

int MuonTGC_Cabling::TGCId::getStation ( ) const
inline

Definition at line 128 of file TGCId.h.

128 { return m_station; }

◆ isAside()

bool MuonTGC_Cabling::TGCId::isAside ( ) const
inline

Definition at line 134 of file TGCId.h.

134 { return (m_side == Aside); }

◆ isBackward()

bool MuonTGC_Cabling::TGCId::isBackward ( ) const

Definition at line 39 of file TGCId.cxx.

39  {
40  if (isEndcap()){
41  if ( !isInner() ) {
42  if(isAside()) return (m_sector%2==1);
43  else return (m_sector%2==0);
44  } else {
45  // EI
46  // Special case of EI11
47  if (m_sector == 15) {
48  if(isAside()) return false;
49  else return true;
50  } else if (m_sector == 16) {
51  if(isAside()) return true;
52  else return false;
53  } else {
54  // A-m_side phi0 F: phi1 F: phi2 B
55  // C-m_side phi0 B: phi1 B: phi2 F
56  if(isAside()) return (m_sector%3==2);
57  else return (m_sector%3!=2);
58  }
59  }
60  } else {
61  if(isAside()) return true; // all Backward
62  else return false; // all Forward
63  }
64 }

◆ isCside()

bool MuonTGC_Cabling::TGCId::isCside ( ) const
inline

Definition at line 135 of file TGCId.h.

135 { return (m_side == Cside); }

◆ isDoublet()

bool MuonTGC_Cabling::TGCId::isDoublet ( ) const
inline

Definition at line 139 of file TGCId.h.

139 { return (m_multiplet == Doublet); }

◆ isEndcap()

bool MuonTGC_Cabling::TGCId::isEndcap ( ) const
inline

Definition at line 142 of file TGCId.h.

142 { return (m_region == Endcap); }

◆ isForward()

bool MuonTGC_Cabling::TGCId::isForward ( ) const
inline

Definition at line 141 of file TGCId.h.

141 { return (m_region == Forward); }

◆ isInner()

bool MuonTGC_Cabling::TGCId::isInner ( ) const
inline

Definition at line 140 of file TGCId.h.

140 { return (m_multiplet == Inner); }

◆ isStrip()

bool MuonTGC_Cabling::TGCId::isStrip ( ) const
inline

Definition at line 136 of file TGCId.h.

136 { return (m_signal == Strip); }

◆ isTriplet()

bool MuonTGC_Cabling::TGCId::isTriplet ( ) const
inline

Definition at line 138 of file TGCId.h.

138 { return (m_multiplet == Triplet); }

◆ isValid()

virtual bool MuonTGC_Cabling::TGCId::isValid ( ) const
inlinevirtual

◆ isWire()

bool MuonTGC_Cabling::TGCId::isWire ( ) const
inline

Definition at line 137 of file TGCId.h.

137 { return (m_signal == Wire); }

◆ setChamber()

void MuonTGC_Cabling::TGCId::setChamber ( int  chamber)
inlinevirtual

Definition at line 152 of file TGCId.h.

152  {
153  m_chamber = chamber;
154 }

◆ setId()

void MuonTGC_Cabling::TGCId::setId ( int  id)
inline

Definition at line 156 of file TGCId.h.

156  {
157  m_id = id;
158 }

◆ setIdType()

void MuonTGC_Cabling::TGCId::setIdType ( IdType  idtype)
inlineprotected

Definition at line 160 of file TGCId.h.

160  {
161  m_idType = idtype;
162 }

◆ setModuleType()

void MuonTGC_Cabling::TGCId::setModuleType ( ModuleType  module)

Definition at line 66 of file TGCId.cxx.

66  {
67  m_module=v_module;
68  if(m_module==WI){
71  }
72  if(m_module==SI){
75  }
76  if(m_module==WD){
79  }
80  if(m_module==SD){
83  }
84  if(m_module==WT){
87  }
88  if(m_module==ST){
91  }
92 }

◆ setMultipletType()

void MuonTGC_Cabling::TGCId::setMultipletType ( MultipletType  multiplet)

Definition at line 104 of file TGCId.cxx.

◆ setOctant()

void MuonTGC_Cabling::TGCId::setOctant ( int  voctant)
virtual

Definition at line 135 of file TGCId.cxx.

135  {
136  m_octant = v_octant;
137 }

◆ setReadoutSector()

void MuonTGC_Cabling::TGCId::setReadoutSector ( int  sector)
protected

◆ setRegionType()

void MuonTGC_Cabling::TGCId::setRegionType ( RegionType  region)
inline

Definition at line 148 of file TGCId.h.

148  {
149  m_region = region;
150 }

◆ setSector()

void MuonTGC_Cabling::TGCId::setSector ( int  vsector)
virtual

Reimplemented in MuonTGC_Cabling::TGCModuleId, and MuonTGC_Cabling::TGCChannelASDIn.

Definition at line 122 of file TGCId.cxx.

122  {
123  m_sector = v_sector;
124  if(m_region==Endcap) {
125  if(m_multiplet==Inner) {
127  } else {
129  }
130  } else if(m_region==Forward) {
132  }
133 }

◆ setSectorModule()

void MuonTGC_Cabling::TGCId::setSectorModule ( int  sectorModule)
protected

Definition at line 159 of file TGCId.cxx.

159  {
160  if(m_octant <0) return;
161 
162  const int MaxModuleInOctant = 15;
163  static const int regionId[MaxModuleInOctant] ={
164  0, 0, 1, 0, 0, 1, 0, 0, 1, 2, 2, 2, 3, 3, 3
165  } ;
166  static const int sectorId[MaxModuleInOctant] ={
167  0, 1, 0, 2, 3, 1, 4, 5, 2, 0, 1, 2, 0, 1, 2
168  };
169 
170  if(sectorModule< 0 || sectorModule>=MaxModuleInOctant) return;
171 
172  if(regionId[sectorModule]==0){
174  setSector(sectorId[sectorModule] + m_octant*(NUM_ENDCAP_SECTOR/NUM_OCTANT));
175 
176  } else if(regionId[sectorModule]==1){
178  setSector(sectorId[sectorModule] + m_octant*(NUM_FORWARD_SECTOR/NUM_OCTANT));
179  } else {
181  if(regionId[sectorModule]==2){ setRegionType(Endcap); }
182  if(regionId[sectorModule]==3){ setRegionType(Forward); }
183  setSector(sectorId[sectorModule] + m_octant*(NUM_INNER_SECTOR/NUM_OCTANT));
184  }
185 }

◆ setSideType()

void MuonTGC_Cabling::TGCId::setSideType ( SideType  side)
inline

Definition at line 144 of file TGCId.h.

144  {
145  m_side = side;
146 }

◆ setSignalType()

void MuonTGC_Cabling::TGCId::setSignalType ( SignalType  signal)

Definition at line 94 of file TGCId.cxx.

◆ setStation()

void MuonTGC_Cabling::TGCId::setStation ( int  vstation)
virtual

Definition at line 114 of file TGCId.cxx.

114  {
115  m_station = v_station;
120 }

Member Data Documentation

◆ m_chamber

int MuonTGC_Cabling::TGCId::m_chamber {-1}
protected

Definition at line 114 of file TGCId.h.

◆ m_id

int MuonTGC_Cabling::TGCId::m_id {-1}
protected

Definition at line 115 of file TGCId.h.

◆ m_idType

IdType MuonTGC_Cabling::TGCId::m_idType {IdType::NoIdType}
private

Definition at line 118 of file TGCId.h.

◆ m_module

ModuleType MuonTGC_Cabling::TGCId::m_module {NoModuleType}
protected

Definition at line 106 of file TGCId.h.

◆ m_multiplet

MultipletType MuonTGC_Cabling::TGCId::m_multiplet {NoMultipletType}
protected

Definition at line 108 of file TGCId.h.

◆ m_octant

int MuonTGC_Cabling::TGCId::m_octant {-1}
protected

Definition at line 112 of file TGCId.h.

◆ m_region

RegionType MuonTGC_Cabling::TGCId::m_region {NoRegionType}
protected

Definition at line 109 of file TGCId.h.

◆ m_sector

int MuonTGC_Cabling::TGCId::m_sector {-1}
protected

Definition at line 113 of file TGCId.h.

◆ m_side

SideType MuonTGC_Cabling::TGCId::m_side {NoSideType}
protected

Definition at line 105 of file TGCId.h.

◆ m_signal

SignalType MuonTGC_Cabling::TGCId::m_signal {NoSignalType}
protected

Definition at line 107 of file TGCId.h.

◆ m_station

int MuonTGC_Cabling::TGCId::m_station {-1}
protected

Definition at line 111 of file TGCId.h.

◆ N_RODS

constexpr int MuonTGC_Cabling::TGCId::N_RODS = 12
staticconstexpr

Definition at line 43 of file TGCId.h.

◆ NUM_ENDCAP_SECTOR

constexpr int MuonTGC_Cabling::TGCId::NUM_ENDCAP_SECTOR = 48
staticconstexpr

Definition at line 40 of file TGCId.h.

◆ NUM_FORWARD_SECTOR

constexpr int MuonTGC_Cabling::TGCId::NUM_FORWARD_SECTOR = 24
staticconstexpr

Definition at line 41 of file TGCId.h.

◆ NUM_INNER_SECTOR

constexpr int MuonTGC_Cabling::TGCId::NUM_INNER_SECTOR = 24
staticconstexpr

Definition at line 42 of file TGCId.h.

◆ NUM_LAYERS

constexpr int MuonTGC_Cabling::TGCId::NUM_LAYERS = 9
staticconstexpr

Definition at line 38 of file TGCId.h.

◆ NUM_OCTANT

constexpr int MuonTGC_Cabling::TGCId::NUM_OCTANT = 8
staticconstexpr

Definition at line 39 of file TGCId.h.

◆ NUM_STATIONS

constexpr int MuonTGC_Cabling::TGCId::NUM_STATIONS = 4
staticconstexpr

in ChannelId

Definition at line 37 of file TGCId.h.


The documentation for this class was generated from the following files:
MuonTGC_Cabling::TGCId::MaxModuleType
@ MaxModuleType
Definition: TGCId.h:48
MuonTGC_Cabling::TGCId::m_station
int m_station
Definition: TGCId.h:111
MuonTGC_Cabling::TGCId::isEndcap
bool isEndcap() const
Definition: TGCId.h:142
MuonTGC_Cabling::TGCId::m_id
int m_id
Definition: TGCId.h:115
MuonTGC_Cabling::TGCId::setRegionType
void setRegionType(RegionType region)
Definition: TGCId.h:148
MuonTGC_Cabling::TGCId::SI
@ SI
Definition: TGCId.h:47
MuonTGC_Cabling::TGCId::m_idType
IdType m_idType
Definition: TGCId.h:118
LArBadChanBlobUtils::Channel
Identifier32::value_type Channel
Definition: LArBadChanBlobUtils.h:24
MuonTGC_Cabling::TGCId::m_module
ModuleType m_module
Definition: TGCId.h:106
calibdata.chamber
chamber
Definition: calibdata.py:32
MuonTGC_Cabling::TGCId::setMultipletType
void setMultipletType(MultipletType multiplet)
Definition: TGCId.cxx:104
ST
Definition: Electrons.cxx:41
MuonTGC_Cabling::TGCId::N_RODS
static constexpr int N_RODS
Definition: TGCId.h:43
MuonTGC_Cabling::TGCId::setSignalType
void setSignalType(SignalType signal)
Definition: TGCId.cxx:94
MuonTGC_Cabling::TGCId::isAside
bool isAside() const
Definition: TGCId.h:134
MuonTGC_Cabling::TGCId::m_side
SideType m_side
Definition: TGCId.h:105
MuonTGC_Cabling::TGCId::setSector
virtual void setSector(int vsector)
Definition: TGCId.cxx:122
MuonTGC_Cabling::TGCId::MaxSideType
@ MaxSideType
Definition: TGCId.h:46
MuonTGC_Cabling::TGCId::NUM_INNER_SECTOR
static constexpr int NUM_INNER_SECTOR
Definition: TGCId.h:42
MuonTGC_Cabling::TGCId::getSectorInOctant
virtual int getSectorInOctant() const
Definition: TGCId.cxx:13
MuonTGC_Cabling::TGCId::isForward
bool isForward() const
Definition: TGCId.h:141
MuonTGC_Cabling::TGCId::SD
@ SD
Definition: TGCId.h:47
TRT::Hit::side
@ side
Definition: HitInfo.h:83
MuonTGC_Cabling::TGCId::NUM_FORWARD_SECTOR
static constexpr int NUM_FORWARD_SECTOR
Definition: TGCId.h:41
MuonTGC_Cabling::TGCId::NUM_OCTANT
static constexpr int NUM_OCTANT
Definition: TGCId.h:39
MuonTGC_Cabling::TGCId::m_region
RegionType m_region
Definition: TGCId.h:109
MuonTGC_Cabling::TGCId::Doublet
@ Doublet
Definition: TGCId.h:51
MuonTGC_Cabling::TGCId::m_sector
int m_sector
Definition: TGCId.h:113
MuonTGC_Cabling::TGCId::WT
@ WT
Definition: TGCId.h:47
MuonTGC_Cabling::TGCId::Strip
@ Strip
Definition: TGCId.h:49
MuonTGC_Cabling::TGCId::MaxChamberType
@ MaxChamberType
Definition: TGCId.h:52
MuonTGC_Cabling::TGCId::WD
@ WD
Definition: TGCId.h:47
MuonTGC_Cabling::TGCId::Inner
@ Inner
Definition: TGCId.h:51
MuonTGC_Cabling::TGCId::Endcap
@ Endcap
Definition: TGCId.h:53
MuonTGC_Cabling::TGCId::WI
@ WI
Definition: TGCId.h:47
MuonTGC_Cabling::TGCId::NoMultipletType
@ NoMultipletType
Definition: TGCId.h:51
id
SG::auxid_t id
Definition: Control/AthContainers/Root/debug.cxx:227
MuonTGC_Cabling::TGCId::m_multiplet
MultipletType m_multiplet
Definition: TGCId.h:108
MuonTGC_Cabling::TGCId::MaxRegionType
@ MaxRegionType
Definition: TGCId.h:54
MuonTGC_Cabling::TGCId::m_chamber
int m_chamber
Definition: TGCId.h:114
MuonTGC_Cabling::TGCId::NoRegionType
@ NoRegionType
Definition: TGCId.h:53
MuonTGC_Cabling::TGCId::NoModuleType
@ NoModuleType
Definition: TGCId.h:47
MuonTGC_Cabling::TGCId::MaxSignalType
@ MaxSignalType
Definition: TGCId.h:50
MuonTGC_Cabling::TGCId::ST
@ ST
Definition: TGCId.h:47
MuonTGC_Cabling::TGCId::getSector
virtual int getSector() const
Definition: TGCId.h:130
MuonTGC_Cabling::TGCId::Cside
@ Cside
Definition: TGCId.h:45
MuonTGC_Cabling::TGCId::NoSideType
@ NoSideType
Definition: TGCId.h:45
MuonTGC_Cabling::TGCId::isInner
bool isInner() const
Definition: TGCId.h:140
MuonTGC_Cabling::TGCId::NUM_ENDCAP_SECTOR
static constexpr int NUM_ENDCAP_SECTOR
Definition: TGCId.h:40
MuonTGC_Cabling::TGCId::Wire
@ Wire
Definition: TGCId.h:49
MuonTGC_Cabling::TGCId::Triplet
@ Triplet
Definition: TGCId.h:51
MuonTGC_Cabling::TGCId::NoSignalType
@ NoSignalType
Definition: TGCId.h:49
MuonTGC_Cabling::TGCId::m_octant
int m_octant
Definition: TGCId.h:112
MuonTGC_Cabling::TGCId::Aside
@ Aside
Definition: TGCId.h:45
MuonTGC_Cabling::TGCId::Forward
@ Forward
Definition: TGCId.h:53
MuonTGC_Cabling::TGCId::m_signal
SignalType m_signal
Definition: TGCId.h:107