19 for(
unsigned int i=0;
i<6;++
i) {
25 LogDebug(
"BuildingSubDetTypeMap") <<
"GeometriDet and GeomDetEnumerators enumerator values of the subdetectors";
26 for(
unsigned int i=0;
i<subdetgd.size();++
i) {
27 assert(subdetgd[
i]->geographicalId().subdetId()>0 && subdetgd[
i]->geographicalId().subdetId()<7);
29 theNumberOfLayers[subdetgd[
i]->geographicalId().subdetId()-1]= subdetgd[
i]->components().size();
30 LogTrace(
"BuildingSubDetTypeMap") <<
"subdet " <<
i
31 <<
" Geometric Det type " << subdetgd[
i]->type()
32 <<
" Geom Det type " <<
theSubDetTypeMap[subdetgd[
i]->geographicalId().subdetId()-1]
33 <<
" detid " << subdetgd[
i]->geographicalId()
34 <<
" subdetid " << subdetgd[
i]->geographicalId().subdetId()
35 <<
" number of layers " << subdetgd[
i]->components().size();
37 LogDebug(
"SubDetTypeMapContent") <<
"Content of theSubDetTypeMap";
38 for(
unsigned int i=1;
i<7;++
i) {
41 LogDebug(
"NumberOfLayers") <<
"Content of theNumberOfLayers";
42 for(
unsigned int i=1;
i<7;++
i) {
89 switch(
id.subdetId()){
109 edm::LogError(
"TrackerGeometry")<<
"ERROR - I was expecting a Tracker Subdetector, I got a "<<
id.subdetId();
172 return static_cast<const TrackerGeomDet *>(p->second);
173 edm::LogError(
"TrackerGeometry")<<
"Invalid DetID: no GeomDetUnit associated";
182 return static_cast<const TrackerGeomDet *>(p->second);
183 edm::LogError(
"TrackerGeometry")<<
"Invalid DetID: no GeomDet associated";
189 if(subdet>=1 && subdet<=6) {
192 throw cms::Exception(
"WrongTrackerSubDet") <<
"Subdetector " << subdet;
198 if(subdet>=1 && subdet<=6) {
201 throw cms::Exception(
"WrongTrackerSubDet") <<
"Subdetector " << subdet;
207 for(
unsigned int i=1;
i<7;++
i) {
virtual const TrackerGeomDet * idToDetUnit(DetId) const
Return the pointer to the GeomDetUnit corresponding to a given DetId.
std::vector< GeomDetType const * > DetTypeContainer
void addDet(GeomDet const *p)
const GeomDetEnumerators::SubDetector geomDetSubDetector(int subdet) const
unsigned int theNumberOfLayers[6]
TrackerGeometry(GeometricDet const *gd=0)
DetIdContainer theDetUnitIds
GeomDetEnumerators::SubDetector theSubDetTypeMap[6]
unsigned int numberOfLayers(int subdet) const
ConstGeometricDetContainer & components()
DetUnitContainer theDetUnits
bool isThere(GeomDetEnumerators::SubDetector subdet) const
uint32_t rawId() const
get the raw id
virtual const DetUnitContainer & detUnits() const
Returm a vector of all GeomDetUnit.
void addDetUnit(GeomDetUnit const *p)
virtual const DetIdContainer & detIds() const
Returm a vector of all GeomDet DetIds (including those of GeomDetUnits)
mapIdToDetUnit theMapUnit
const DetContainer & detsTEC() const
DetTypeContainer theDetTypes
virtual ~TrackerGeometry()
void addType(GeomDetType const *p)
virtual const DetTypeContainer & detTypes() const
Return a vector of all det types.
const DetContainer & detsPXB() const
DetId geographicalId() const
The label of this GeomDet.
static const GeomDetEnumerators::SubDetector geometricDetToGeomDet(GeometricDet::GDEnumType gdenum)
const DetContainer & detsTIB() const
std::vector< GeometricDet const * > ConstGeometricDetContainer
void addDetUnitId(DetId p)
virtual const DetIdContainer & detUnitIds() const
Returm a vector of all GeomDetUnit DetIds.
const DetContainer & detsPXF() const
const DetContainer & detsTOB() const
std::vector< GeomDet const * > DetContainer
std::vector< GeomDetUnit const * > DetUnitContainer
virtual const DetContainer & dets() const
Returm a vector of all GeomDet (including all GeomDetUnits)
const DetContainer & detsTID() const
virtual const TrackerGeomDet * idToDet(DetId) const
std::vector< DetId > DetIdContainer