CMS 3D CMS Logo

CloseComponentsMerger.h
Go to the documentation of this file.
1 #ifndef CloseComponentsMerger_H
2 #define CloseComponentsMerger_H
3 
7 
8 #include <map>
9 #include <algorithm>
10 
11 
18 template <unsigned int N>
20 
21  private:
24  using SingleStatePtr = std::shared_ptr<SingleState>;
25 
26  public:
27 
30 
31  CloseComponentsMerger* clone() const override
32  {
33  return new CloseComponentsMerger(*this);
34  }
35 
39  MultiState merge(const MultiState& mgs) const override;
40 
41  MultiState mergeOld(const MultiState& mgs) const;
42 
43 
44 public:
45  typedef std::multimap< double, SingleStatePtr > SingleStateMap;
46  typedef std::pair< SingleStatePtr, typename SingleStateMap::iterator > MinDistResult;
47 
48 private:
49 
50 // std::pair< SingleState, SingleStateMap::iterator >
51  MinDistResult
52  compWithMinDistToLargestWeight(SingleStateMap&) const;
53 
56 
57 };
58 
59 #include "TrackingTools/GsfTools/interface/CloseComponentsMerger.icc"
60 
61 #endif // CloseComponentsMerger_H
DeepCopyPointerByClone< DistanceBetweenComponents< N > > theDistance
Mixture of multi-variate gaussian states.
std::multimap< double, SingleStatePtr > SingleStateMap
MultiState merge(const MultiState &mgs) const override
MultiState mergeOld(const MultiState &mgs) const
MinDistResult compWithMinDistToLargestWeight(SingleStateMap &) const
CloseComponentsMerger * clone() const override
std::pair< SingleStatePtr, typename SingleStateMap::iterator > MinDistResult
CloseComponentsMerger(int n, const DistanceBetweenComponents< N > *distance)
std::shared_ptr< SingleState > SingleStatePtr