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 Attributes
GeometricSearchTracker Class Reference

#include <GeometricSearchTracker.h>

Inheritance diagram for GeometricSearchTracker:
DetLayerGeometry

Public Member Functions

std::vector< DetLayer * > const & allLayers () const
 
std::vector< BarrelDetLayer * >
const & 
barrelLayers () const
 
const DetLayerdetLayer (const DetId &id) const
 obsolete method. Use idToLayer() instead. More...
 
std::vector< ForwardDetLayer * >
const & 
forwardLayers () const
 
 GeometricSearchTracker (const std::vector< BarrelDetLayer * > &pxlBar, const std::vector< BarrelDetLayer * > &tib, const std::vector< BarrelDetLayer * > &tob, const std::vector< ForwardDetLayer * > &negPxlFwd, const std::vector< ForwardDetLayer * > &negTid, const std::vector< ForwardDetLayer * > &negTec, const std::vector< ForwardDetLayer * > &posPxlFwd, const std::vector< ForwardDetLayer * > &posTid, const std::vector< ForwardDetLayer * > &posTec)
 
virtual const DetLayeridToLayer (const DetId &detId) const
 Give the DetId of a module, returns the pointer to the corresponding DetLayer. More...
 
std::vector< ForwardDetLayer * >
const & 
negForwardLayers () const
 
std::vector< ForwardDetLayer * >
const & 
negPixelForwardLayers () const
 
std::vector< ForwardDetLayer * >
const & 
negTecLayers () const
 
std::vector< ForwardDetLayer * >
const & 
negTidLayers () const
 
std::vector< BarrelDetLayer * >
const & 
pixelBarrelLayers () const
 
std::vector< ForwardDetLayer * >
const & 
posForwardLayers () const
 
std::vector< ForwardDetLayer * >
const & 
posPixelForwardLayers () const
 
std::vector< ForwardDetLayer * >
const & 
posTecLayers () const
 
std::vector< ForwardDetLayer * >
const & 
posTidLayers () const
 
std::vector< BarrelDetLayer * >
const & 
tibLayers () const
 
std::vector< BarrelDetLayer * >
const & 
tobLayers () const
 
virtual ~GeometricSearchTracker ()
 
- Public Member Functions inherited from DetLayerGeometry
 DetLayerGeometry ()
 

Private Attributes

std::vector< DetLayer * > theAllLayers
 
std::vector< BarrelDetLayer * > theBarrelLayers
 
std::vector< ForwardDetLayer * > theForwardLayers
 
std::vector< ForwardDetLayer * > theNegForwardLayers
 
std::vector< ForwardDetLayer * > theNegPixelForwardLayers
 
std::vector< ForwardDetLayer * > theNegTecLayers
 
std::vector< ForwardDetLayer * > theNegTidLayers
 
std::vector< BarrelDetLayer * > thePixelBarrelLayers
 
std::vector< ForwardDetLayer * > thePosForwardLayers
 
std::vector< ForwardDetLayer * > thePosPixelForwardLayers
 
std::vector< ForwardDetLayer * > thePosTecLayers
 
std::vector< ForwardDetLayer * > thePosTidLayers
 
std::vector< BarrelDetLayer * > theTibLayers
 
std::vector< BarrelDetLayer * > theTobLayers
 

Detailed Description

GeometricSearchTracker implementation

Definition at line 13 of file GeometricSearchTracker.h.

Constructor & Destructor Documentation

GeometricSearchTracker::GeometricSearchTracker ( const std::vector< BarrelDetLayer * > &  pxlBar,
const std::vector< BarrelDetLayer * > &  tib,
const std::vector< BarrelDetLayer * > &  tob,
const std::vector< ForwardDetLayer * > &  negPxlFwd,
const std::vector< ForwardDetLayer * > &  negTid,
const std::vector< ForwardDetLayer * > &  negTec,
const std::vector< ForwardDetLayer * > &  posPxlFwd,
const std::vector< ForwardDetLayer * > &  posTid,
const std::vector< ForwardDetLayer * > &  posTec 
)

Definition at line 6 of file GeometricSearchTracker.cc.

References barrelLayers(), negForwardLayers(), negPixelForwardLayers(), negTecLayers(), negTidLayers(), pixelBarrelLayers(), posForwardLayers(), posPixelForwardLayers(), posTecLayers(), posTidLayers(), theAllLayers, theBarrelLayers, theForwardLayers, theNegForwardLayers, theNegPixelForwardLayers, theNegTecLayers, theNegTidLayers, thePixelBarrelLayers, thePosForwardLayers, thePosPixelForwardLayers, thePosTecLayers, thePosTidLayers, theTibLayers, theTobLayers, tibLayers(), and tobLayers().

14  :
15  thePixelBarrelLayers(pxlBar.begin(),pxlBar.end()),
16  theTibLayers(tib.begin(),tib.end()),
17  theTobLayers(tob.begin(),tob.end()),
18  theNegPixelForwardLayers(negPxlFwd.begin(),negPxlFwd.end()),
19  theNegTidLayers(negTid.begin(),negTid.end()),
20  theNegTecLayers(negTec.begin(),negTec.end()),
21  thePosPixelForwardLayers(posPxlFwd.begin(),posPxlFwd.end()),
22  thePosTidLayers(posTid.begin(),posTid.end()),
23  thePosTecLayers(posTec.begin(),posTec.end())
24 {
26  theBarrelLayers.insert(theBarrelLayers.end(),theTibLayers.begin(),theTibLayers.end());
27  theBarrelLayers.insert(theBarrelLayers.end(),theTobLayers.begin(),theTobLayers.end());
28 
32 
36 
37 
40  theAllLayers.assign(theBarrelLayers.begin(),theBarrelLayers.end());
41  theAllLayers.insert(theAllLayers.end(),
42  theForwardLayers.begin(),
43  theForwardLayers.end());
44 
45  edm::LogInfo("TkDetLayers")
46  << "------ GeometricSearchTracker constructed with: ------" << "\n"
47  << "n pxlBarLayers: " << this->pixelBarrelLayers().size() << "\n"
48  << "n tibLayers: " << this->tibLayers().size() << "\n"
49  << "n tobLayers: " << this->tobLayers().size() << "\n"
50  << "n negPxlFwdLayers: " << this->negPixelForwardLayers().size() << "\n"
51  << "n negPxlFwdLayers: " << this->posPixelForwardLayers().size() << "\n"
52  << "n negTidLayers: " << this->negTidLayers().size() << "\n"
53  << "n posTidLayers: " << this->posTidLayers().size() << "\n"
54  << "n negTecLayers: " << this->negTecLayers().size() << "\n"
55  << "n posTecLayers: " << this->posTecLayers().size() << "\n"
56 
57  << "n barreLayers: " << this->barrelLayers().size() << "\n"
58  << "n negforwardLayers: " << this->negForwardLayers().size() << "\n"
59  << "n posForwardLayers: " << this->posForwardLayers().size() ;
60 }
std::vector< ForwardDetLayer * > theForwardLayers
std::vector< ForwardDetLayer * > const & posTecLayers() const
std::vector< ForwardDetLayer * > theNegTidLayers
std::vector< BarrelDetLayer * > theTibLayers
std::vector< ForwardDetLayer * > thePosTidLayers
std::vector< BarrelDetLayer * > const & barrelLayers() const
std::vector< ForwardDetLayer * > const & negTecLayers() const
std::vector< BarrelDetLayer * > theBarrelLayers
std::vector< BarrelDetLayer * > thePixelBarrelLayers
std::vector< BarrelDetLayer * > theTobLayers
std::vector< ForwardDetLayer * > const & posPixelForwardLayers() const
std::vector< ForwardDetLayer * > theNegPixelForwardLayers
std::vector< ForwardDetLayer * > thePosPixelForwardLayers
std::vector< ForwardDetLayer * > const & negForwardLayers() const
std::vector< ForwardDetLayer * > const & posForwardLayers() const
std::vector< ForwardDetLayer * > thePosForwardLayers
std::vector< ForwardDetLayer * > thePosTecLayers
std::vector< BarrelDetLayer * > const & tibLayers() const
std::vector< ForwardDetLayer * > const & posTidLayers() const
std::vector< DetLayer * > theAllLayers
std::vector< ForwardDetLayer * > theNegForwardLayers
std::vector< ForwardDetLayer * > const & negTidLayers() const
std::vector< ForwardDetLayer * > theNegTecLayers
std::vector< BarrelDetLayer * > const & tobLayers() const
std::vector< BarrelDetLayer * > const & pixelBarrelLayers() const
std::vector< ForwardDetLayer * > const & negPixelForwardLayers() const
GeometricSearchTracker::~GeometricSearchTracker ( )
virtual

Definition at line 63 of file GeometricSearchTracker.cc.

References theAllLayers.

63  {
64  for(vector<DetLayer*>::const_iterator it=theAllLayers.begin(); it!=theAllLayers.end();it++){
65  delete *it;
66  }
67 
68 }
std::vector< DetLayer * > theAllLayers

Member Function Documentation

std::vector<DetLayer*> const& GeometricSearchTracker::allLayers ( ) const
inline
std::vector<BarrelDetLayer*> const& GeometricSearchTracker::barrelLayers ( ) const
inline
const DetLayer* GeometricSearchTracker::detLayer ( const DetId id) const
inline
std::vector<ForwardDetLayer*> const& GeometricSearchTracker::forwardLayers ( ) const
inline
const DetLayer * GeometricSearchTracker::idToLayer ( const DetId detId) const
virtual

Give the DetId of a module, returns the pointer to the corresponding DetLayer.

Reimplemented from DetLayerGeometry.

Definition at line 81 of file GeometricSearchTracker.cc.

References PXFDetId::disk(), PXBDetId::layer(), TOBDetId::layer(), TIBDetId::layer(), PixelSubdetector::PixelBarrel, PixelSubdetector::PixelEndcap, StripSubdetector::TEC, theNegPixelForwardLayers, theNegTecLayers, theNegTidLayers, thePixelBarrelLayers, thePosPixelForwardLayers, thePosTecLayers, thePosTidLayers, theTibLayers, theTobLayers, StripSubdetector::TIB, StripSubdetector::TID, StripSubdetector::TOB, TIDDetId::wheel(), and TECDetId::wheel().

Referenced by GlobalDetLayerGeometry::idToLayer().

82 {
83  switch(id.subdetId()) {
85  //edm::LogInfo(TkDetLayers) << "TIB layer n: " << TIBDetId(id).layer() ;
86  return theTibLayers[TIBDetId(id).layer()-1];
87  break;
88 
90  //edm::LogInfo(TkDetLayers) << "TOB layer n: " << TOBDetId(id).layer() ;
91  return theTobLayers[TOBDetId(id).layer()-1];
92  break;
93 
95  //edm::LogInfo(TkDetLayers) << "TID wheel n: " << TIDDetId(id).wheel() ;
96  if(TIDDetId(id).side() ==1 ) {
97  return theNegTidLayers[TIDDetId(id).wheel()-1];
98  }else if( TIDDetId(id).side() == 2 ) {
99  return thePosTidLayers[TIDDetId(id).wheel()-1];
100  }
101  break;
102 
104  //edm::LogInfo(TkDetLayers) << "TEC wheel n: " << TECDetId(id).wheel() ;
105  if(TECDetId(id).side() ==1 ) {
106  return theNegTecLayers[TECDetId(id).wheel()-1];
107  }else if( TECDetId(id).side() == 2 ) {
108  return thePosTecLayers[TECDetId(id).wheel()-1];
109  }
110  break;
111 
113  //edm::LogInfo(TkDetLayers) << "PixelBarrel layer n: " << PXBDetId(id).layer() ;
114  return thePixelBarrelLayers[PXBDetId(id).layer()-1];
115  break;
116 
118  //edm::LogInfo(TkDetLayers) << "PixelEndcap disk n: " << PXFDetId(id).disk() ;
119  if(PXFDetId(id).side() ==1 ) {
120  return theNegPixelForwardLayers[PXFDetId(id).disk()-1];
121  }else if( PXFDetId(id).side() == 2 ) {
122  return thePosPixelForwardLayers[PXFDetId(id).disk()-1];
123  }
124  break;
125 
126  default:
127  edm::LogError("TkDetLayers") << "ERROR:layer not found!" ;
128  // throw(something);
129  }
130  return 0; //just to avoid compile warnings
131 }
unsigned int layer() const
layer id
Definition: TOBDetId.h:39
std::vector< ForwardDetLayer * > theNegTidLayers
std::vector< BarrelDetLayer * > theTibLayers
unsigned int layer() const
layer id
Definition: PXBDetId.h:35
std::vector< ForwardDetLayer * > thePosTidLayers
std::vector< BarrelDetLayer * > thePixelBarrelLayers
std::vector< BarrelDetLayer * > theTobLayers
std::vector< ForwardDetLayer * > theNegPixelForwardLayers
std::vector< ForwardDetLayer * > thePosPixelForwardLayers
unsigned int disk() const
disk id
Definition: PXFDetId.h:43
unsigned int wheel() const
wheel id
Definition: TECDetId.h:52
unsigned int layer() const
layer id
Definition: TIBDetId.h:41
std::vector< ForwardDetLayer * > thePosTecLayers
std::vector< ForwardDetLayer * > theNegTecLayers
unsigned int wheel() const
wheel id
Definition: TIDDetId.h:50
std::vector<ForwardDetLayer*> const& GeometricSearchTracker::negForwardLayers ( ) const
inline
std::vector<ForwardDetLayer*> const& GeometricSearchTracker::negPixelForwardLayers ( ) const
inline
std::vector<ForwardDetLayer*> const& GeometricSearchTracker::negTecLayers ( ) const
inline
std::vector<ForwardDetLayer*> const& GeometricSearchTracker::negTidLayers ( ) const
inline
std::vector<BarrelDetLayer*> const& GeometricSearchTracker::pixelBarrelLayers ( ) const
inline
std::vector<ForwardDetLayer*> const& GeometricSearchTracker::posForwardLayers ( ) const
inline
std::vector<ForwardDetLayer*> const& GeometricSearchTracker::posPixelForwardLayers ( ) const
inline
std::vector<ForwardDetLayer*> const& GeometricSearchTracker::posTecLayers ( ) const
inline
std::vector<ForwardDetLayer*> const& GeometricSearchTracker::posTidLayers ( ) const
inline
std::vector<BarrelDetLayer*> const& GeometricSearchTracker::tibLayers ( ) const
inline
std::vector<BarrelDetLayer*> const& GeometricSearchTracker::tobLayers ( ) const
inline

Member Data Documentation

std::vector<DetLayer*> GeometricSearchTracker::theAllLayers
private
std::vector<BarrelDetLayer*> GeometricSearchTracker::theBarrelLayers
private

Definition at line 57 of file GeometricSearchTracker.h.

Referenced by barrelLayers(), and GeometricSearchTracker().

std::vector<ForwardDetLayer*> GeometricSearchTracker::theForwardLayers
private

Definition at line 58 of file GeometricSearchTracker.h.

Referenced by forwardLayers(), and GeometricSearchTracker().

std::vector<ForwardDetLayer*> GeometricSearchTracker::theNegForwardLayers
private

Definition at line 59 of file GeometricSearchTracker.h.

Referenced by GeometricSearchTracker(), and negForwardLayers().

std::vector<ForwardDetLayer*> GeometricSearchTracker::theNegPixelForwardLayers
private
std::vector<ForwardDetLayer*> GeometricSearchTracker::theNegTecLayers
private

Definition at line 68 of file GeometricSearchTracker.h.

Referenced by GeometricSearchTracker(), idToLayer(), and negTecLayers().

std::vector<ForwardDetLayer*> GeometricSearchTracker::theNegTidLayers
private

Definition at line 67 of file GeometricSearchTracker.h.

Referenced by GeometricSearchTracker(), idToLayer(), and negTidLayers().

std::vector<BarrelDetLayer*> GeometricSearchTracker::thePixelBarrelLayers
private

Definition at line 62 of file GeometricSearchTracker.h.

Referenced by GeometricSearchTracker(), idToLayer(), and pixelBarrelLayers().

std::vector<ForwardDetLayer*> GeometricSearchTracker::thePosForwardLayers
private

Definition at line 60 of file GeometricSearchTracker.h.

Referenced by GeometricSearchTracker(), and posForwardLayers().

std::vector<ForwardDetLayer*> GeometricSearchTracker::thePosPixelForwardLayers
private
std::vector<ForwardDetLayer*> GeometricSearchTracker::thePosTecLayers
private

Definition at line 71 of file GeometricSearchTracker.h.

Referenced by GeometricSearchTracker(), idToLayer(), and posTecLayers().

std::vector<ForwardDetLayer*> GeometricSearchTracker::thePosTidLayers
private

Definition at line 70 of file GeometricSearchTracker.h.

Referenced by GeometricSearchTracker(), idToLayer(), and posTidLayers().

std::vector<BarrelDetLayer*> GeometricSearchTracker::theTibLayers
private

Definition at line 63 of file GeometricSearchTracker.h.

Referenced by GeometricSearchTracker(), idToLayer(), and tibLayers().

std::vector<BarrelDetLayer*> GeometricSearchTracker::theTobLayers
private

Definition at line 64 of file GeometricSearchTracker.h.

Referenced by GeometricSearchTracker(), idToLayer(), and tobLayers().