CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
PixelBladeBuilder.cc
Go to the documentation of this file.
2 
4 
6 
7 using namespace edm;
8 using namespace std;
9 
10 PixelBlade* PixelBladeBuilder:: build(const GeometricDet* geometricDetFrontPanel,
11  const GeometricDet* geometricDetBackPanel,
12  const TrackerGeometry* theGeomDetGeometry)
13 {
14  vector<const GeometricDet*> frontGeometricDets = geometricDetFrontPanel->components();
15  vector<const GeometricDet*> backGeometricDets = geometricDetBackPanel->components();
16 
17  vector<const GeomDet*> theFrontGeomDets;
18  vector<const GeomDet*> theBackGeomDets;
19 
20  for(vector<const GeometricDet*>::iterator it=frontGeometricDets.begin();
21  it!=frontGeometricDets.end();it++){
22  const GeomDet* theGeomDet = theGeomDetGeometry->idToDet( (*it)->geographicalID() );
23  theFrontGeomDets.push_back(theGeomDet);
24  }
25 
26  for(vector<const GeometricDet*>::iterator it=backGeometricDets.begin();
27  it!=backGeometricDets.end();it++){
28  const GeomDet* theGeomDet = theGeomDetGeometry->idToDet( (*it)->geographicalID() );
29  theBackGeomDets.push_back(theGeomDet);
30  }
31 
32  //edm::LogInfo(TkDetLayers) << "FrontGeomDet.size(): " << theFrontGeomDets.size() ;
33  //edm::LogInfo(TkDetLayers) << "BackGeomDet.size(): " << theBackGeomDets.size() ;
34 
35  return new PixelBlade(theFrontGeomDets,theBackGeomDets);
36 }
37 
38 
39 
40 
virtual const GeomDet * idToDet(DetId) const
PixelBlade * build(const GeometricDet *geometricDetFrontPanel, const GeometricDet *geometricDetBackPanel, const TrackerGeometry *theGeomDetGeometry)
GeometricDetContainer & components()
Definition: GeometricDet.h:163