CMatchManager.h
Go to the documentation of this file.
1 /**
2  * \file CMatchManager.h
3  *
4  * \ingroup CMTool
5  *
6  * \brief Class def header for a class CMatchManager
7  *
8  * @author kazuhiro
9  */
10 
11 /** \addtogroup CMTool
12 
13  @{*/
14 #ifndef RECOTOOL_CMATCHMANAGER_H
15 #define RECOTOOL_CMATCHMANAGER_H
16 
17 #include <stddef.h>
18 
19 #include "CMManagerBase.h"
20 #include "CMatchBookKeeper.h"
21 
22 namespace cmtool {
23 
24  class CFloatAlgoBase;
25  /**
26  \class CMatchManager
27  A class that instantiates merging algorithm(s) and run.
28  The book-keeping of merged cluster sets are done by CMatchBookKeeper.
29  */
30  class CMatchManager : public CMManagerBase {
31 
32  private:
33  /// Default constructor is private because we need an argument to configure w/ # planes in the detector
34  CMatchManager();
35 
36  public:
37  CMatchManager(size_t nplanes);
38 
39  /// Default destructor
40  virtual ~CMatchManager() {}
41 
42  /// Method to reset itself
43  virtual void Reset();
44 
45  /// A simple method to add an algorithm for merging
46  void
48  {
49  _match_algo = algo;
50  }
51 
52  /// A method to obtain book keeper
53  const CMatchBookKeeper&
54  GetBookKeeper() const
55  {
56  return _book_keeper;
57  }
58 
59  protected:
60  //
61  // FMWK functions override
62  //
63 
64  /// FMWK function called @ beginning of Process()
65  virtual void EventBegin();
66 
67  /// FMWK function called @ beginning of iterative loop inside Process()
68  virtual void IterationBegin();
69 
70  /// FMWK function called @ iterative loop inside Process()
71  virtual bool IterationProcess(util::GeometryUtilities const& gser);
72 
73  /// FMWK function called @ end of iterative loop inside Process()
74  virtual void IterationEnd();
75 
76  /// FMWK function called @ end of Process()
77  virtual void EventEnd();
78 
79  protected:
80  /// Book keeper instance
82 
83  /// Merging algorithm
85 
86  /// Number of planes
87  size_t _nplanes;
88  };
89 }
90 
91 #endif
92 /** @} */ // end of doxygen group
virtual void EventEnd()
FMWK function called @ end of Process()
Class def header for a class CMatchBookKeeper.
virtual void Reset()
Method to reset itself.
::cmtool::CFloatAlgoBase * _match_algo
Merging algorithm.
Definition: CMatchManager.h:84
CMatchManager()
Default constructor is private because we need an argument to configure w/ # planes in the detector...
void AddMatchAlgo(CFloatAlgoBase *algo)
A simple method to add an algorithm for merging.
Definition: CMatchManager.h:47
CMatchBookKeeper _book_keeper
Book keeper instance.
Definition: CMatchManager.h:81
virtual bool IterationProcess(util::GeometryUtilities const &gser)
FMWK function called @ iterative loop inside Process()
virtual void EventBegin()
FMWK function called @ beginning of Process()
virtual ~CMatchManager()
Default destructor.
Definition: CMatchManager.h:40
const CMatchBookKeeper & GetBookKeeper() const
A method to obtain book keeper.
Definition: CMatchManager.h:54
virtual void IterationEnd()
FMWK function called @ end of iterative loop inside Process()
virtual void IterationBegin()
FMWK function called @ beginning of iterative loop inside Process()
Class def header for a class CMManagerBase.
size_t _nplanes
Number of planes.
Definition: CMatchManager.h:87