CMS 3D CMS Logo

List of all members | Public Member Functions
GeometricSearchTrackerBuilder Class Reference

#include <GeometricSearchTrackerBuilder.h>

Public Member Functions

GeometricSearchTrackerbuild (const GeometricDet *theGeometricTracker, const TrackerGeometry *theGeomDetGeometry, const TrackerTopology *tTopo) __attribute__((cold))
 
 GeometricSearchTrackerBuilder ()
 
 ~GeometricSearchTrackerBuilder ()
 

Detailed Description

GeometricSearchTrackerBuilder implementation

Definition at line 14 of file GeometricSearchTrackerBuilder.h.

Constructor & Destructor Documentation

◆ GeometricSearchTrackerBuilder()

GeometricSearchTrackerBuilder::GeometricSearchTrackerBuilder ( )
inline

Definition at line 16 of file GeometricSearchTrackerBuilder.h.

16 {}

◆ ~GeometricSearchTrackerBuilder()

GeometricSearchTrackerBuilder::~GeometricSearchTrackerBuilder ( )
inline

Definition at line 17 of file GeometricSearchTrackerBuilder.h.

17 {}

Member Function Documentation

◆ build()

GeometricSearchTracker * GeometricSearchTrackerBuilder::build ( const GeometricDet theGeometricTracker,
const TrackerGeometry theGeomDetGeometry,
const TrackerTopology tTopo 
)

Definition at line 24 of file GeometricSearchTrackerBuilder.cc.

26  {
27  PixelBarrelLayerBuilder aPixelBarrelLayerBuilder;
28  Phase2OTBarrelLayerBuilder aPhase2OTBarrelLayerBuilder;
31  Phase2EndcapLayerBuilder aPhase2EndcapLayerBuilder;
32  TIBLayerBuilder aTIBLayerBuilder;
33  TOBLayerBuilder aTOBLayerBuilder;
34  TIDLayerBuilder aTIDLayerBuilder;
35  TECLayerBuilder aTECLayerBuilder;
36 
37  vector<BarrelDetLayer const*> thePxlBarLayers;
38  vector<BarrelDetLayer const*> theTIBLayers;
39  vector<BarrelDetLayer const*> theTOBLayers;
40  vector<ForwardDetLayer const*> theNegPxlFwdLayers;
41  vector<ForwardDetLayer const*> thePosPxlFwdLayers;
42  vector<ForwardDetLayer const*> theNegTIDLayers;
43  vector<ForwardDetLayer const*> thePosTIDLayers;
44  vector<ForwardDetLayer const*> theNegTECLayers;
45  vector<ForwardDetLayer const*> thePosTECLayers;
46 
47  vector<const GeometricDet*> theGeometricDetLayers = theGeometricTracker->components();
48  for (vector<const GeometricDet*>::const_iterator it = theGeometricDetLayers.begin();
49  it != theGeometricDetLayers.end();
50  it++) {
51  if ((*it)->type() == GeometricDet::PixelBarrel) {
52  vector<const GeometricDet*> thePxlBarGeometricDetLayers = (*it)->components();
53  for (vector<const GeometricDet*>::const_iterator it2 = thePxlBarGeometricDetLayers.begin();
54  it2 != thePxlBarGeometricDetLayers.end();
55  it2++) {
56  thePxlBarLayers.push_back(aPixelBarrelLayerBuilder.build(*it2, theGeomDetGeometry));
57  }
58  }
59 
60  if ((*it)->type() == GeometricDet::PixelPhase1Barrel) {
61  vector<const GeometricDet*> thePxlBarGeometricDetLayers = (*it)->components();
62  for (vector<const GeometricDet*>::const_iterator it2 = thePxlBarGeometricDetLayers.begin();
63  it2 != thePxlBarGeometricDetLayers.end();
64  it2++) {
65  thePxlBarLayers.push_back(aPixelBarrelLayerBuilder.build(*it2, theGeomDetGeometry));
66  }
67  }
68 
69  if ((*it)->type() == GeometricDet::PixelPhase2Barrel) {
70  vector<const GeometricDet*> thePxlBarGeometricDetLayers = (*it)->components();
71  for (vector<const GeometricDet*>::const_iterator it2 = thePxlBarGeometricDetLayers.begin();
72  it2 != thePxlBarGeometricDetLayers.end();
73  it2++) {
74  thePxlBarLayers.push_back(aPixelBarrelLayerBuilder.build(*it2, theGeomDetGeometry));
75  }
76  }
77 
78  if ((*it)->type() == GeometricDet::TIB) {
79  vector<const GeometricDet*> theTIBGeometricDetLayers = (*it)->components();
80  for (vector<const GeometricDet*>::const_iterator it2 = theTIBGeometricDetLayers.begin();
81  it2 != theTIBGeometricDetLayers.end();
82  it2++) {
83  theTIBLayers.push_back(aTIBLayerBuilder.build(*it2, theGeomDetGeometry));
84  }
85  }
86 
87  if ((*it)->type() == GeometricDet::TOB) {
88  vector<const GeometricDet*> theTOBGeometricDetLayers = (*it)->components();
89  for (vector<const GeometricDet*>::const_iterator it2 = theTOBGeometricDetLayers.begin();
90  it2 != theTOBGeometricDetLayers.end();
91  it2++) {
92  theTOBLayers.push_back(aTOBLayerBuilder.build(*it2, theGeomDetGeometry));
93  }
94  }
95 
96  if ((*it)->type() == GeometricDet::OTPhase2Barrel) {
97  vector<const GeometricDet*> theTOBGeometricDetLayers = (*it)->components();
98  for (vector<const GeometricDet*>::const_iterator it2 = theTOBGeometricDetLayers.begin();
99  it2 != theTOBGeometricDetLayers.end();
100  it2++) {
101  theTOBLayers.push_back(aPhase2OTBarrelLayerBuilder.build(*it2, theGeomDetGeometry));
102  }
103  }
104 
105  if ((*it)->type() == GeometricDet::PixelEndCap) {
106  vector<const GeometricDet*> thePxlFwdGeometricDetLayers = (*it)->components();
107  for (vector<const GeometricDet*>::const_iterator it2 = thePxlFwdGeometricDetLayers.begin();
108  it2 != thePxlFwdGeometricDetLayers.end();
109  it2++) {
110  if ((*it2)->positionBounds().z() < 0)
111  theNegPxlFwdLayers.push_back(aPixelForwardLayerBuilder.build(*it2, theGeomDetGeometry));
112  if ((*it2)->positionBounds().z() > 0)
113  thePosPxlFwdLayers.push_back(aPixelForwardLayerBuilder.build(*it2, theGeomDetGeometry));
114  }
115  }
116 
117  if ((*it)->type() == GeometricDet::PixelPhase1EndCap) {
118  vector<const GeometricDet*> thePxlFwdGeometricDetLayers = (*it)->components();
119  for (vector<const GeometricDet*>::const_iterator it2 = thePxlFwdGeometricDetLayers.begin();
120  it2 != thePxlFwdGeometricDetLayers.end();
121  it2++) {
122  if ((*it2)->positionBounds().z() < 0)
123  theNegPxlFwdLayers.push_back(aPhase1PixelForwardLayerBuilder.build(*it2, theGeomDetGeometry));
124  if ((*it2)->positionBounds().z() > 0)
125  thePosPxlFwdLayers.push_back(aPhase1PixelForwardLayerBuilder.build(*it2, theGeomDetGeometry));
126  }
127  }
128 
129  if ((*it)->type() == GeometricDet::PixelPhase2EndCap) {
130  vector<const GeometricDet*> thePxlFwdGeometricDetLayers = (*it)->components();
131  for (vector<const GeometricDet*>::const_iterator it2 = thePxlFwdGeometricDetLayers.begin();
132  it2 != thePxlFwdGeometricDetLayers.end();
133  it2++) {
134  //FIXME: this is just to keep the compatibility with the PixelPhase1 extension layout
135  //hopefully we can get rid of it soon
136  if ((*it2)->positionBounds().z() < 0) {
137  if ((*it2)->type() == GeometricDet::PixelPhase2FullDisk ||
138  (*it2)->type() == GeometricDet::PixelPhase2ReducedDisk)
139  theNegPxlFwdLayers.push_back(aPhase1PixelForwardLayerBuilder.build(*it2, theGeomDetGeometry));
140  else if ((*it2)->type() == GeometricDet::PixelPhase2TDRDisk)
141  theNegPxlFwdLayers.push_back(aPhase2EndcapLayerBuilder.build(*it2, theGeomDetGeometry, false));
142  } else if ((*it2)->positionBounds().z() > 0) {
143  if ((*it2)->type() == GeometricDet::PixelPhase2FullDisk ||
144  (*it2)->type() == GeometricDet::PixelPhase2ReducedDisk)
145  thePosPxlFwdLayers.push_back(aPhase1PixelForwardLayerBuilder.build(*it2, theGeomDetGeometry));
146  else if ((*it2)->type() == GeometricDet::PixelPhase2TDRDisk)
147  thePosPxlFwdLayers.push_back(aPhase2EndcapLayerBuilder.build(*it2, theGeomDetGeometry, false));
148  } else {
149  edm::LogError("TkDetLayers") << "In PixelPhase2EndCap the disks are neither PixelPhase2FullDisk nor "
150  "PixelPhase2ReducedDisk nor PixelPhase2TDRDisk...";
151  }
152  }
153  }
154 
155  if ((*it)->type() == GeometricDet::TID) {
156  vector<const GeometricDet*> theTIDGeometricDetLayers = (*it)->components();
157  for (vector<const GeometricDet*>::const_iterator it2 = theTIDGeometricDetLayers.begin();
158  it2 != theTIDGeometricDetLayers.end();
159  it2++) {
160  if ((*it2)->positionBounds().z() < 0)
161  theNegTIDLayers.push_back(aTIDLayerBuilder.build(*it2, theGeomDetGeometry));
162  if ((*it2)->positionBounds().z() > 0)
163  thePosTIDLayers.push_back(aTIDLayerBuilder.build(*it2, theGeomDetGeometry));
164  }
165  }
166 
167  if ((*it)->type() == GeometricDet::OTPhase2EndCap) {
168  vector<const GeometricDet*> theTIDGeometricDetLayers = (*it)->components();
169  for (vector<const GeometricDet*>::const_iterator it2 = theTIDGeometricDetLayers.begin();
170  it2 != theTIDGeometricDetLayers.end();
171  it2++) {
172  if ((*it2)->positionBounds().z() < 0)
173  theNegTIDLayers.push_back(aPhase2EndcapLayerBuilder.build(*it2, theGeomDetGeometry, true));
174  if ((*it2)->positionBounds().z() > 0)
175  thePosTIDLayers.push_back(aPhase2EndcapLayerBuilder.build(*it2, theGeomDetGeometry, true));
176  }
177  }
178 
179  if ((*it)->type() == GeometricDet::TEC) {
180  vector<const GeometricDet*> theTECGeometricDetLayers = (*it)->components();
181  for (vector<const GeometricDet*>::const_iterator it2 = theTECGeometricDetLayers.begin();
182  it2 != theTECGeometricDetLayers.end();
183  it2++) {
184  if ((*it2)->positionBounds().z() < 0)
185  theNegTECLayers.push_back(aTECLayerBuilder.build(*it2, theGeomDetGeometry));
186  if ((*it2)->positionBounds().z() > 0)
187  thePosTECLayers.push_back(aTECLayerBuilder.build(*it2, theGeomDetGeometry));
188  }
189  }
190  }
191 
192  return new GeometricSearchTracker(thePxlBarLayers,
193  theTIBLayers,
194  theTOBLayers,
195  theNegPxlFwdLayers,
196  theNegTIDLayers,
197  theNegTECLayers,
198  thePosPxlFwdLayers,
199  thePosTIDLayers,
200  thePosTECLayers,
201  tTopo);
202 }

References PixelBarrelLayerBuilder::build(), TOBLayerBuilder::build(), Phase2EndcapLayerBuilder::build(), Phase2OTBarrelLayerBuilder::build(), TIDLayerBuilder::build(), TIBLayerBuilder::build(), TECLayerBuilder::build(), PixelForwardLayerBuilder< T1, T2 >::build(), GeometricDet::components(), GeometricDet::OTPhase2Barrel, GeometricDet::OTPhase2EndCap, GeometricDet::PixelBarrel, GeometricDet::PixelEndCap, GeometricDet::PixelPhase1Barrel, GeometricDet::PixelPhase1EndCap, GeometricDet::PixelPhase2Barrel, GeometricDet::PixelPhase2EndCap, GeometricDet::PixelPhase2FullDisk, GeometricDet::PixelPhase2ReducedDisk, GeometricDet::PixelPhase2TDRDisk, GeometricDet::TEC, GeometricDet::TIB, GeometricDet::TID, and GeometricDet::TOB.

Referenced by TrackerRecoGeometryESProducer::produce().

TIBLayerBuilder::build
TIBLayer * build(const GeometricDet *aTIBLayer, const TrackerGeometry *theGeomDetGeometry) __attribute__((cold))
Definition: TIBLayerBuilder.cc:10
GeometricDet::PixelEndCap
Definition: GeometricDet.h:56
Phase2EndcapLayerBuilder
Definition: Phase2EndcapLayerBuilder.h:14
GeometricDet::PixelPhase2ReducedDisk
Definition: GeometricDet.h:83
GeometricDet::components
ConstGeometricDetContainer & components()
Definition: GeometricDet.h:139
GeometricDet::TID
Definition: GeometricDet.h:58
PixelBarrelLayerBuilder::build
PixelBarrelLayer * build(const GeometricDet *aPixelBarrelLayer, const TrackerGeometry *theGeomDetGeometry) __attribute__((cold))
Definition: PixelBarrelLayerBuilder.cc:7
PixelForwardLayerBuilder::build
ForwardDetLayer * build(const GeometricDet *aPixelForwardLayer, const TrackerGeometry *theGeomDetGeometry) __attribute__((cold))
Definition: PixelForwardLayerBuilder.h:28
GeometricDet::PixelBarrel
Definition: GeometricDet.h:55
PixelBarrelLayerBuilder
Definition: PixelBarrelLayerBuilder.h:14
GeometricDet::OTPhase2Barrel
Definition: GeometricDet.h:76
GeometricDet::PixelPhase1EndCap
Definition: GeometricDet.h:73
GeometricDet::PixelPhase2Barrel
Definition: GeometricDet.h:79
TIBLayerBuilder
Definition: TIBLayerBuilder.h:14
PixelForwardLayerBuilder
Definition: PixelForwardLayerBuilder.h:20
GeometricDet::PixelPhase2TDRDisk
Definition: GeometricDet.h:84
GeometricDet::PixelPhase2EndCap
Definition: GeometricDet.h:80
edm::LogError
Definition: MessageLogger.h:183
TECLayerBuilder::build
TECLayer * build(const GeometricDet *aTECLayer, const TrackerGeometry *theGeomDetGeometry) __attribute__((cold))
Definition: TECLayerBuilder.cc:7
GeometricDet::PixelPhase1Barrel
Definition: GeometricDet.h:72
GeometricDet::OTPhase2EndCap
Definition: GeometricDet.h:75
GeometricDet::TIB
Definition: GeometricDet.h:57
TOBLayerBuilder::build
TOBLayer * build(const GeometricDet *aTOBLayer, const TrackerGeometry *theGeomDetGeometry) __attribute__((cold))
Definition: TOBLayerBuilder.cc:10
Phase2EndcapLayerBuilder::build
Phase2EndcapLayer * build(const GeometricDet *aPhase2EndcapLayer, const TrackerGeometry *theGeomDetGeometry, const bool isOuterTracker) __attribute__((cold))
Definition: Phase2EndcapLayerBuilder.cc:7
TIDLayerBuilder
Definition: TIDLayerBuilder.h:14
GeometricDet::PixelPhase2FullDisk
Definition: GeometricDet.h:82
Phase2OTBarrelLayerBuilder::build
Phase2OTBarrelLayer * build(const GeometricDet *aPhase2OTBarrelLayer, const TrackerGeometry *theGeomDetGeometry) __attribute__((cold))
Definition: Phase2OTBarrelLayerBuilder.cc:9
GeometricDet::TOB
Definition: GeometricDet.h:59
GeometricSearchTracker
Definition: GeometricSearchTracker.h:14
TECLayerBuilder
Definition: TECLayerBuilder.h:14
TIDLayerBuilder::build
TIDLayer * build(const GeometricDet *aTIDLayer, const TrackerGeometry *theGeomDetGeometry) __attribute__((cold))
Definition: TIDLayerBuilder.cc:7
TOBLayerBuilder
Definition: TOBLayerBuilder.h:14
Phase2OTBarrelLayerBuilder
Definition: Phase2OTBarrelLayerBuilder.h:14
GeometricDet::TEC
Definition: GeometricDet.h:60