CMS 3D CMS Logo

AlignableIndexer.h
Go to the documentation of this file.
1 #ifndef Alignment_CommonAlignment_Counters_H
2 #define Alignment_CommonAlignment_Counters_H
3 
22 #include <map>
23 #include <functional>
24 
28 
29 class TrackerTopology;
30 namespace align
31 {
32  using Counter = std::function<unsigned int(align::ID)>;
33 }
34 
36 {
37  public:
38 
40  AlignableIndexer() = default;
41  AlignableIndexer(const AlignableIndexer&) = default;
42  AlignableIndexer& operator=(const AlignableIndexer&) = default;
44  AlignableIndexer& operator=(AlignableIndexer&&) = default;
45  virtual ~AlignableIndexer() = default;
46 
48  virtual align::Counter get(align::StructureType, const AlignableObjectId&) const;
49 
50 protected:
51  std::map<align::StructureType, align::Counter> theCounters;
52 
53 };
54 
55 #endif
std::map< align::StructureType, align::Counter > theCounters
std::function< unsigned int(align::ID)> Counter
Allows conversion between type and name, and vice-versa.