25 : fromDDD_(p.getParameter<
bool>(
"fromDDD"))
32 std::shared_ptr<std::vector<GeometricDetExtra> >
34 auto gde = std::make_shared<std::vector<GeometricDetExtra> >();
46 putOne((*gde), tracker, ev, 0);
47 std::vector<const GeometricDet*> tc = tracker->
components();
48 std::vector<const GeometricDet*>::const_iterator git = tc.begin();
49 std::vector<const GeometricDet*>::const_iterator egit = tc.end();
54 for (; git!= egit; ++git) {
55 ev.
goTo((*git)->navType());
56 putOne((*gde), *git, ev, lev);
57 std::vector<const GeometricDet*> inone = (*git)->components();
59 if ( inone.empty() ) ++count;
60 std::vector<const GeometricDet*>::const_iterator git2 = inone.begin();
61 std::vector<const GeometricDet*>::const_iterator egit2 = inone.end();
63 for (; git2 != egit2; ++git2) {
64 ev.
goTo((*git2)->navType());
65 putOne((*gde), *git2, ev, lev);
66 std::vector<const GeometricDet*> intwo= (*git2)->components();
68 if ( intwo.empty() ) ++count;
69 std::vector<const GeometricDet*>::const_iterator git3 = intwo.begin();
70 std::vector<const GeometricDet*>::const_iterator egit3 = intwo.end();
72 for (; git3 != egit3; ++git3) {
73 ev.
goTo((*git3)->navType());
74 putOne((*gde), *git3, ev, lev);
75 std::vector<const GeometricDet*> inthree= (*git3)->components();
77 if ( inthree.empty() ) ++count;
78 std::vector<const GeometricDet*>::const_iterator git4 = inthree.begin();
79 std::vector<const GeometricDet*>::const_iterator egit4 = inthree.end();
81 for (; git4 != egit4; ++git4) {
82 ev.
goTo((*git4)->navType());
83 putOne((*gde), *git4, ev, lev);
84 std::vector<const GeometricDet*> infour= (*git4)->components();
86 if ( infour.empty() ) ++count;
87 std::vector<const GeometricDet*>::const_iterator git5 = infour.begin();
88 std::vector<const GeometricDet*>::const_iterator egit5 = infour.end();
90 for (; git5 != egit5; ++git5) {
91 ev.
goTo((*git5)->navType());
92 putOne((*gde), *git5, ev, lev);
93 std::vector<const GeometricDet*> infive= (*git5)->components();
95 if ( infive.empty() ) ++count;
96 std::vector<const GeometricDet*>::const_iterator git6 = infive.begin();
97 std::vector<const GeometricDet*>::const_iterator egit6 = infive.end();
99 for (; git6 != egit6; ++git6) {
100 ev.
goTo((*git6)->navType());
101 putOne((*gde), *git6, ev, lev);
102 std::vector<const GeometricDet*> insix= (*git6)->components();
104 if ( insix.empty() ){
107 edm::LogError(
"GeometricDetExtra") <<
"Hierarchy has exceeded hard-coded level 6 for Tracker " ;
124 std::map<uint32_t, const GeometricDet*> helperMap;
126 helperMap[gd->geographicalID()] =
tracker;
127 std::vector<const GeometricDet*> tc = tracker->
components();
128 std::vector<const GeometricDet*>::const_iterator git = tc.begin();
129 std::vector<const GeometricDet*>::const_iterator egit = tc.end();
130 for (; git!= egit; ++git) {
131 helperMap[(*git)->geographicalID()] = (*git);
132 std::vector<const GeometricDet*> inone = (*git)->components();
133 std::vector<const GeometricDet*>::const_iterator git2 = inone.begin();
134 std::vector<const GeometricDet*>::const_iterator egit2 = inone.end();
135 for (; git2 != egit2; ++git2) {
136 helperMap[(*git2)->geographicalID()] = (*git2);
137 std::vector<const GeometricDet*> intwo= (*git2)->components();
138 std::vector<const GeometricDet*>::const_iterator git3 = intwo.begin();
139 std::vector<const GeometricDet*>::const_iterator egit3 = intwo.end();
140 for (; git3 != egit3; ++git3) {
141 helperMap[(*git3)->geographicalID()] = (*git3);
142 std::vector<const GeometricDet*> inthree= (*git3)->components();
143 std::vector<const GeometricDet*>::const_iterator git4 = inthree.begin();
144 std::vector<const GeometricDet*>::const_iterator egit4 = inthree.end();
145 for (; git4 != egit4; ++git4) {
146 helperMap[(*git4)->geographicalID()] = (*git4);
147 std::vector<const GeometricDet*> infour= (*git4)->components();
148 std::vector<const GeometricDet*>::const_iterator git5 = infour.begin();
149 std::vector<const GeometricDet*>::const_iterator egit5 = infour.end();
150 for (; git5 != egit5; ++git5) {
151 helperMap[(*git5)->geographicalID()] = (*git5);
152 std::vector<const GeometricDet*> infive= (*git5)->components();
153 std::vector<const GeometricDet*>::const_iterator git6 = infive.begin();
154 std::vector<const GeometricDet*>::const_iterator egit6 = infive.end();
155 for (; git6 != egit6; ++git6) {
156 helperMap[(*git6)->geographicalID()] = (*git6);
157 if ( !(*git6)->components().empty() ){
158 edm::LogError(
"GeometricDetExtra") <<
"Hierarchy has exceeded hard-coded level of 6 for Tracker " ;
167 const std::vector<PGeometricDetExtra::Item>& pgdes = pgde->
pgdes_;
168 gde->reserve(pgdes.size());
169 std::vector<DDExpandedNode> evs;
171 for (
const auto & pgde : pgdes) {
173 gde->emplace_back(
GeometricDetExtra(helperMap[pgde._geographicalId], pgde._geographicalId, evs
174 , pgde._volume, pgde._density, pgde._weight, pgde._copy
175 , pgde._material, nm));
178 return std::shared_ptr<std::vector<GeometricDetExtra> >(gde);
nav_type const & navType() const
void setWhatProduced(T *iThis, const es::Label &iLabel=es::Label())
ConstGeometricDetContainer & components()
const DDGeoHistory & geoHistory() const
The list of ancestors up to the root-node of the current node.
const DepRecordT & getRecord() const
void get(HolderT &iHolder) const
int copyno() const
Copy number associated with the current node.
DetId geographicalId() const
#define DEFINE_FWK_EVENTSETUP_MODULE(type)
ConstGeometricDetContainer deepComponents() const
bool goTo(const nav_type &)
transversed the DDExpandedView according to the given stack of sibling numbers
const DDLogicalPart & logicalPart() const
The logical-part of the current node in the expanded-view.
Provides an exploded view of the detector (tree-view)