CMS 3D CMS Logo

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
CmsTrackerSubStrctBuilder.cc
Go to the documentation of this file.
12 #include <vector>
13 
14 #include <bitset>
15 
16 template <class FilteredView>
18  CmsTrackerLayerBuilder<FilteredView> theCmsTrackerLayerBuilder;
19  CmsTrackerOTLayerBuilder<FilteredView> theCmsTrackerOTLayerBuilder;
20  CmsTrackerWheelBuilder<FilteredView> theCmsTrackerWheelBuilder;
21  CmsTrackerDiskBuilder<FilteredView> theCmsTrackerDiskBuilder;
22 
23  GeometricDet* subdet = new GeometricDet(&fv,
29  theCmsTrackerLayerBuilder.build(fv, subdet, s);
30  break;
32  theCmsTrackerOTLayerBuilder.build(fv, subdet, s);
33  break;
35  theCmsTrackerWheelBuilder.build(fv, subdet, s);
36  break;
37  case GeometricDet::disk:
38  theCmsTrackerDiskBuilder.build(fv, subdet, s);
39  break;
40 
41  default:
42  edm::LogError("CmsTrackerSubStrctBuilder") << " ERROR - I was expecting a Layer ,Wheel or Disk... I got a "
44  }
45 
46  g->addComponent(subdet);
47 }
48 
49 template <class FilteredView>
52 
53  switch (comp.front()->type()) {
55  std::sort(comp.begin(), comp.end(), CmsTrackerLevelBuilderHelper::isLessR);
56  break;
58  std::sort(comp.begin(), comp.end(), CmsTrackerLevelBuilderHelper::isLessR);
59  break;
61  std::sort(comp.begin(), comp.end(), CmsTrackerLevelBuilderHelper::isLessModZ);
62  break;
63  case GeometricDet::disk:
64  std::sort(comp.begin(), comp.end(), CmsTrackerLevelBuilderHelper::isLessModZ);
65  break;
66  default:
67  edm::LogError("CmsTrackerSubStrctBuilder")
68  << "ERROR - wrong SubDet to sort..... " << det->components().front()->type();
69  }
70 
71  for (uint32_t i = 0; i < comp.size(); i++) {
72  det->component(i)->setGeographicalID(i + 1); // Every subdetector: Layer/Disk/Wheel Number
73  }
74 }
75 
GeometricDet::OTPhase2Layer
Definition: GeometricDet.h:73
ExtractStringFromDDD::getString
static std::string getString(const std::string &, FilteredView *)
CmsTrackerLevelBuilder
Definition: CmsTrackerLevelBuilder.h:31
mps_fire.i
i
Definition: mps_fire.py:428
MessageLogger.h
CmsTrackerSubStrctBuilder.h
GeometricDet::components
ConstGeometricDetContainer & components()
Definition: GeometricDet.h:149
CmsTrackerSubStrctBuilder::sortNS
void sortNS(FilteredView &, GeometricDet *) override
Definition: CmsTrackerSubStrctBuilder.cc:50
GeometricDet::wheel
Definition: GeometricDet.h:58
AlCaHLTBitMon_QueryRunRegistry.comp
comp
Definition: AlCaHLTBitMon_QueryRunRegistry.py:249
ExtractStringFromDDD
Definition: ExtractStringFromDDD.h:12
CmsTrackerLayerBuilder.h
CmsTrackerLevelBuilderHelper::isLessR
static bool isLessR(const GeometricDet *a, const GeometricDet *b)
Definition: CmsTrackerLevelBuilder.cc:140
CmsTrackerDiskBuilder
Definition: CmsTrackerDiskBuilder.h:12
alignCSCRings.s
s
Definition: alignCSCRings.py:92
DDFilteredView.h
GeometricDet::setGeographicalID
void setGeographicalID(DetId id)
Definition: GeometricDet.h:97
CmsTrackerWheelBuilder.h
GeometricDet::disk
Definition: GeometricDet.h:66
GeometricDet
Definition: GeometricDet.h:31
DDFilteredView.h
CmsTrackerLevelBuilderHelper::isLessModZ
static bool isLessModZ(const GeometricDet *a, const GeometricDet *b)
Definition: CmsTrackerLevelBuilder.cc:40
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
CmsTrackerLevelBuilder::build
void build(FilteredView &, GeometricDet *, const std::string &) override
CmsTrackerDiskBuilder.h
gainCalibHelper::gainCalibPI::type
type
Definition: SiPixelGainCalibHelper.h:39
CmsTrackerWheelBuilder
Definition: CmsTrackerWheelBuilder.h:12
edm::LogError
Log< level::Error, false > LogError
Definition: MessageLogger.h:123
CmsTrackerOTLayerBuilder.h
GeometricDet.h
CmsTrackerLayerBuilder
Definition: CmsTrackerLayerBuilder.h:12
CmsTrackerOTLayerBuilder
Definition: CmsTrackerOTLayerBuilder.h:12
ExtractStringFromDDD.h
GeometricDet::component
GeometricDet * component(size_t index)
Definition: GeometricDet.h:145
GeometricDet::ConstGeometricDetContainer
std::vector< GeometricDet const * > ConstGeometricDetContainer
Definition: GeometricDet.h:34
DetId.h
CmsTrackerSubStrctBuilder
Definition: CmsTrackerSubStrctBuilder.h:12
GeometricDet::layer
Definition: GeometricDet.h:57
CmsTrackerSubStrctBuilder::buildComponent
void buildComponent(FilteredView &, GeometricDet *, const std::string &) override
Definition: CmsTrackerSubStrctBuilder.cc:17
g
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