CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CmsTrackerSubStrctBuilder.cc
Go to the documentation of this file.
10 #include <vector>
11 
12 #include <bitset>
13 
15 
16  CmsTrackerLayerBuilder theCmsTrackerLayerBuilder ;
17  CmsTrackerWheelBuilder theCmsTrackerWheelBuilder;
18  CmsTrackerDiskBuilder theCmsTrackerDiskBuilder;
19 
23  theCmsTrackerLayerBuilder.build(fv,subdet,s);
24  break;
26  theCmsTrackerWheelBuilder.build(fv,subdet,s);
27  break;
28  case GeometricDet::disk:
29  theCmsTrackerDiskBuilder.build(fv,subdet,s);
30  break;
31 
32  default:
33  edm::LogError("CmsTrackerSubStrctBuilder")<<" ERROR - I was expecting a Layer ,Wheel or Disk... I got a "<<ExtractStringFromDDD::getString(s,&fv);
34  }
35 
36  g->addComponent(subdet);
37 
38 }
39 
42 
43  switch(comp.front()->type()){
44  case GeometricDet::layer: std::sort(comp.begin(),comp.end(),LessR()); break;
45  case GeometricDet::wheel: std::sort(comp.begin(),comp.end(),LessModZ()); break;
46  case GeometricDet::disk: std::sort(comp.begin(),comp.end(),LessModZ()); break;
47 
48  default:
49  edm::LogError("CmsTrackerSubStrctBuilder")<<"ERROR - wrong SubDet to sort..... "<<det->components().front()->type();
50  }
51 
52  for(uint32_t i=0; i<comp.size(); i++){
53  comp[i]->setGeographicalID(i+1); // Every subdetector: Layer/Disk/Wheel Number
54  }
55 
56 }
57 
static std::string getString(std::string const &, DDFilteredView *)
int i
Definition: DBlmapReader.cc:9
void addComponent(GeometricDet *)
virtual void sortNS(DDFilteredView &, GeometricDet *)
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e g
Definition: Activities.doc:4
std::vector< GeometricDet const * > GeometricDetContainer
Definition: GeometricDet.h:36
virtual void build(DDFilteredView &, GeometricDet *, std::string)
virtual void buildComponent(DDFilteredView &, GeometricDet *, std::string)
GeometricDetContainer & components()
Definition: GeometricDet.h:163
GeometricDet::GeometricEnumType type(std::string const &) const
CmsTrackerStringToEnum theCmsTrackerStringToEnum