CMS 3D CMS Logo

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

#include <DataFormats/SiStripDetId/interface/SiStripSubStructure.h>

Public Member Functions

void getTECDetectors (const std::vector< uint32_t > &inputDetRawIds, std::vector< uint32_t > &tecDetRawIds, uint32_t side=0, uint32_t wheel=0, uint32_t petal_bkw_frw=0, uint32_t petal=0, uint32_t ring=0, uint32_t ster=0) const
 
void getTIBDetectors (const std::vector< uint32_t > &inputDetRawIds, std::vector< uint32_t > &tibDetRawIds, uint32_t layer=0, uint32_t bkw_frw=0, uint32_t int_ext=0, uint32_t string=0) const
 
void getTIDDetectors (const std::vector< uint32_t > &inputDetRawIds, std::vector< uint32_t > &tidDetRawIds, uint32_t side=0, uint32_t wheel=0, uint32_t ring=0, uint32_t ster=0) const
 
void getTOBDetectors (const std::vector< uint32_t > &inputDetRawIds, std::vector< uint32_t > &tobDetRawIds, uint32_t layer=0, uint32_t bkw_frw=0, uint32_t rod=0) const
 
 SiStripSubStructure ()
 
 ~SiStripSubStructure ()
 

Private Member Functions

const SiStripSubStructureoperator= (const SiStripSubStructure &)
 
 SiStripSubStructure (const SiStripSubStructure &)
 

Detailed Description

Description: <Assign detector Ids to different substructures of the SiStripTracker: TOB, TIB, etc>

Usage: <usage>

Definition at line 25 of file SiStripSubStructure.h.

Constructor & Destructor Documentation

SiStripSubStructure::SiStripSubStructure ( )

Definition at line 23 of file SiStripSubStructure.cc.

23  {
24 }
SiStripSubStructure::~SiStripSubStructure ( )

Definition at line 26 of file SiStripSubStructure.cc.

26  {
27 }
SiStripSubStructure::SiStripSubStructure ( const SiStripSubStructure )
private

Member Function Documentation

void SiStripSubStructure::getTECDetectors ( const std::vector< uint32_t > &  inputDetRawIds,
std::vector< uint32_t > &  tecDetRawIds,
uint32_t  side = 0,
uint32_t  wheel = 0,
uint32_t  petal_bkw_frw = 0,
uint32_t  petal = 0,
uint32_t  ring = 0,
uint32_t  ster = 0 
) const

Definition at line 100 of file SiStripSubStructure.cc.

References asciidump::at, TECDetId::petal(), TECDetId::ring(), TECDetId::side(), SiStripDetId::stereo(), DetId::subdetId(), StripSubdetector::TEC, and TECDetId::wheel().

Referenced by SiStripBaseCondObjDQM::analysisOnDemand(), SiStripDQMProfileToTkMapConverter::beginRun(), SiStripBaseCondObjDQM::bookSummaryProfileMEs(), SiStripMonitorDigi::createMEs(), SiStripMonitorCluster::createMEs(), TkLayerMap::createTEC(), SiStripLorentzAngleDQM::fillMEsForLayer(), SiStripBaseCondObjDQM::GetSameLayerDetId(), and SiStripBaseCondObjDQM::selectModules().

107  {
108  // loop over all input detectors
109  for(vector<uint32_t>::const_iterator it = inputDetRawIds.begin(); it!=inputDetRawIds.end();it++){
110  uint32_t therawid = (*it); // raw id of single detector
111  TECDetId potentialTEC = TECDetId(therawid); // build TECDetId, at this point is just DetId, but do not want to cast twice
112  if( potentialTEC.subdetId() == int (StripSubdetector::TEC) ){ // check if subdetector field is a TEC, both tested numbers are int
113  if( // check if TEC is from the ones requested
114  ( (potentialTEC.side()==requested_side) || requested_side==0 ) // take everything if default value is 0
115  && ( (potentialTEC.wheel()==requested_wheel) || requested_wheel==0 )
116  && ( ((potentialTEC.petal()).at(0)==(requested_petal_bkw_frw-1)) || requested_petal_bkw_frw==0 )
117  && ( ((potentialTEC.petal()).at(1)==requested_petal) || requested_petal==0 )
118  && ( (potentialTEC.ring()==requested_ring) || requested_ring==0 )
119  && ( (potentialTEC.stereo()==requested_ster) || requested_ster==0 )
120  ){
121  tecDetRawIds.push_back(therawid); // add detector to list of selected TECdets
122  }
123  }
124  }
125 }
uint32_t stereo() const
Definition: SiStripDetId.h:162
unsigned int side() const
positive or negative id
Definition: TECDetId.h:47
std::vector< unsigned int > petal() const
petal id
Definition: TECDetId.h:61
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:39
unsigned int wheel() const
wheel id
Definition: TECDetId.h:52
unsigned int ring() const
ring id
Definition: TECDetId.h:71
list at
Definition: asciidump.py:428
void SiStripSubStructure::getTIBDetectors ( const std::vector< uint32_t > &  inputDetRawIds,
std::vector< uint32_t > &  tibDetRawIds,
uint32_t  layer = 0,
uint32_t  bkw_frw = 0,
uint32_t  int_ext = 0,
uint32_t  string = 0 
) const

Definition at line 30 of file SiStripSubStructure.cc.

References asciidump::at, TIBDetId::layer(), TIBDetId::string(), DetId::subdetId(), and StripSubdetector::TIB.

Referenced by SiStripGainCosmicCalculator::algoBeginJob(), SiStripBaseCondObjDQM::analysisOnDemand(), SiStripDQMProfileToTkMapConverter::beginRun(), SiStripBaseCondObjDQM::bookSummaryProfileMEs(), SiStripMonitorDigi::createMEs(), SiStripMonitorCluster::createMEs(), TkLayerMap::createTIB(), SiStripLorentzAngleDQM::fillMEsForLayer(), SiStripBaseCondObjDQM::GetSameLayerDetId(), and SiStripBaseCondObjDQM::selectModules().

35  {
36  // loop over all input detectors
37  for(vector<uint32_t>::const_iterator it = inputDetRawIds.begin(); it!=inputDetRawIds.end();it++){
38  uint32_t therawid = (*it); // raw id of single detector
39  TIBDetId potentialTIB = TIBDetId(therawid); // build TIBDetId, at this point is just DetId, but do not want to cast twice
40  if( potentialTIB.subdetId() == int (StripSubdetector::TIB) ){ // check if subdetector field is a TIB, both tested numbers are int
41  if( // check if TIB is from the ones requested
42  ( (potentialTIB.layer()==requested_layer) || requested_layer==0 ) // take everything if default value is 0
43  && ( ((potentialTIB.string()).at(0)==(requested_bkw_frw)) || requested_bkw_frw==0 )
44  && ( ((potentialTIB.string()).at(1)==(requested_int_ext)) || requested_int_ext==0 )
45  && ( ((potentialTIB.string()).at(2)==requested_string) || requested_string==0 )
46  ){
47  tibDetRawIds.push_back(therawid); // add detector to list of selected TIBdets
48  }
49  }
50  }
51 }
std::vector< unsigned int > string() const
string id
Definition: TIBDetId.h:53
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:39
unsigned int layer() const
layer id
Definition: TIBDetId.h:41
list at
Definition: asciidump.py:428
void SiStripSubStructure::getTIDDetectors ( const std::vector< uint32_t > &  inputDetRawIds,
std::vector< uint32_t > &  tidDetRawIds,
uint32_t  side = 0,
uint32_t  wheel = 0,
uint32_t  ring = 0,
uint32_t  ster = 0 
) const

Definition at line 54 of file SiStripSubStructure.cc.

References TIDDetId::ring(), TIDDetId::side(), SiStripDetId::stereo(), DetId::subdetId(), StripSubdetector::TID, and TIDDetId::wheel().

Referenced by SiStripBaseCondObjDQM::analysisOnDemand(), SiStripDQMProfileToTkMapConverter::beginRun(), SiStripBaseCondObjDQM::bookSummaryProfileMEs(), SiStripMonitorDigi::createMEs(), SiStripMonitorCluster::createMEs(), TkLayerMap::createTID(), SiStripLorentzAngleDQM::fillMEsForLayer(), SiStripBaseCondObjDQM::GetSameLayerDetId(), and SiStripBaseCondObjDQM::selectModules().

59  {
60  // loop over all input detectors
61  for(vector<uint32_t>::const_iterator it = inputDetRawIds.begin(); it!=inputDetRawIds.end();it++){
62  uint32_t therawid = (*it); // raw id of single detector
63  TIDDetId potentialTID = TIDDetId(therawid); // build TIDDetId, at this point is just DetId, but do not want to cast twice
64  if( potentialTID.subdetId() == int (StripSubdetector::TID) ){ // check if subdetector field is a TID, both tested numbers are int
65  if( // check if TID is from the ones requested
66  ( (potentialTID.side()==requested_side) || requested_side==0 ) // take everything if default value is 0
67  && ( (potentialTID.wheel()==requested_wheel) || requested_wheel==0 )
68  && ( (potentialTID.ring()==requested_ring) || requested_ring==0 )
69  && ( (potentialTID.stereo()==requested_ster) || requested_ster==0 )
70  ){
71  tidDetRawIds.push_back(therawid); // add detector to list of selected TIDdets
72  }
73  }
74  }
75 }
uint32_t stereo() const
Definition: SiStripDetId.h:162
unsigned int ring() const
ring id
Definition: TIDDetId.h:55
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:39
unsigned int side() const
positive or negative id
Definition: TIDDetId.h:45
unsigned int wheel() const
wheel id
Definition: TIDDetId.h:50
void SiStripSubStructure::getTOBDetectors ( const std::vector< uint32_t > &  inputDetRawIds,
std::vector< uint32_t > &  tobDetRawIds,
uint32_t  layer = 0,
uint32_t  bkw_frw = 0,
uint32_t  rod = 0 
) const

Definition at line 78 of file SiStripSubStructure.cc.

References asciidump::at, TOBDetId::layer(), TOBDetId::rod(), DetId::subdetId(), and StripSubdetector::TOB.

Referenced by SiStripGainCosmicCalculator::algoBeginJob(), SiStripBaseCondObjDQM::analysisOnDemand(), SiStripDQMProfileToTkMapConverter::beginRun(), SiStripBaseCondObjDQM::bookSummaryProfileMEs(), SiStripMonitorDigi::createMEs(), SiStripMonitorCluster::createMEs(), TkLayerMap::createTOB(), SiStripLorentzAngleDQM::fillMEsForLayer(), SiStripBaseCondObjDQM::GetSameLayerDetId(), and SiStripBaseCondObjDQM::selectModules().

82  {
83  // loop over all input detectors
84  for(vector<uint32_t>::const_iterator it = inputDetRawIds.begin(); it!=inputDetRawIds.end();it++){
85  uint32_t therawid = (*it); // raw id of single detector
86  TOBDetId potentialTOB = TOBDetId(therawid); // build TOBDetId, at this point is just DetId, but do not want to cast twice
87  if( potentialTOB.subdetId() == int (StripSubdetector::TOB) ){ // check if subdetector field is a TOB, both tested numbers are int
88  if( // check if TOB is from the ones requested
89  ( (potentialTOB.layer()==requested_layer) || requested_layer==0 ) // take everything if default value is 0
90  && ( ((potentialTOB.rod()).at(0)==(requested_bkw_frw)) || requested_bkw_frw==0 )
91  && ( ((potentialTOB.rod()).at(1)==requested_rod) || requested_rod==0 )
92  ){
93  tobDetRawIds.push_back(therawid); // add detector to list of selected TOBdets
94  }
95  }
96  }
97 }
unsigned int layer() const
layer id
Definition: TOBDetId.h:39
std::vector< unsigned int > rod() const
rod id
Definition: TOBDetId.h:49
int subdetId() const
get the contents of the subdetector field (not cast into any detector&#39;s numbering enum) ...
Definition: DetId.h:39
list at
Definition: asciidump.py:428
const SiStripSubStructure& SiStripSubStructure::operator= ( const SiStripSubStructure )
private