CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions
TrackAnalyzer::KeyHasher Struct Reference

Public Member Functions

std::size_t operator() (const Key &k) const
 

Detailed Description

Definition at line 421 of file TrackAnalyzer.h.

Member Function Documentation

std::size_t TrackAnalyzer::KeyHasher::operator() ( const Key k) const
inline

Definition at line 422 of file TrackAnalyzer.h.

References TrackAnalyzer::Key::det, TrackAnalyzer::Key::monitoring, and TrackAnalyzer::Key::subdet.

422  {
423  // 3 bits (0x7) for kind of monitoring (7 kinds at most)
424  // next 8 bits to the subdetector (255 subdetectors at most)
425  // next 8 bits to the detector (255 detectors at most)
426  return (size_t)(
427  (k.monitoring & (0x7)) |
428  ((k.subdet & (0xff)) << 3) |
429  ((k.det & (0xff)) << 11));
430  }