CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
SiStripHashedDetIdESModule.cc
Go to the documentation of this file.
8 
9 using namespace sistrip;
10 
11 // -----------------------------------------------------------------------------
12 //
15 {
16  edm::LogVerbatim("HashedDetId")
17  << "[SiStripHashedDetIdESSourceFromGeom::" << __func__ << "]"
18  << " Constructing object...";
19 }
20 
21 // -----------------------------------------------------------------------------
22 //
24  edm::LogVerbatim("HashedDetId")
25  << "[SiStripHashedDetIdESSourceFromGeom::" << __func__ << "]"
26  << " Destructing object...";
27 }
28 
29 // -----------------------------------------------------------------------------
30 //
32  edm::LogVerbatim("HashedDetId")
33  << "[SiStripHashedDetIdFakeESSource::" << __func__ << "]"
34  << " Building \"fake\" hashed DetId map from geometry";
35 
37  rcd.getRecord<TrackerDigiGeometryRecord>().get( geom );
38 
39  std::vector<uint32_t> dets;
40  dets.reserve(16000);
41 
42  TrackerGeometry::DetUnitContainer::const_iterator iter = geom->detUnits().begin();
43  for( ; iter != geom->detUnits().end(); ++iter ) {
44  const StripGeomDetUnit* strip = dynamic_cast<StripGeomDetUnit*>(*iter);
45  if ( strip ) { dets.push_back( (strip->geographicalId()).rawId() ); }
46  }
48  << "[SiStripHashedDetIdESModule::" << __func__ << "]"
49  << " Retrieved " << dets.size()
50  << " sistrip DetIds from geometry!";
51 
52  // Create hash map object
55  << "[SiStripHashedDetIdESModule::" << __func__ << "]"
56  << " DetId hash map: " << std::endl
57  << *hash;
58 
59  return hash;
60 
61 }
62 
Provides dense hash map in place of DetId.
Abstract base class for producer of SiStripHashedDetId record.
DetId geographicalId() const
The label of this GeomDet.
Definition: GeomDet.h:72
static const char mlDqmCommon_[]
#define LogTrace(id)
virtual SiStripHashedDetId * make(const SiStripHashedDetIdRcd &)
SiStripHashedDetIdESModule(const edm::ParameterSet &)