Bayeux  3.4.1
Core Foundation library for SuperNEMO
algo.h
Go to the documentation of this file.
1 
3 #ifndef MY_ALGO_H
4 #define MY_ALGO_H
5 
6 // Standard library:
7 #include <string>
8 
9 // Third party:
10 // - Bayeux/datatools::
11 
13 namespace datatools {
14  // Forward declaration:
15  class properties;
16 }
17 
51 
53 namespace my {
54 
56  class algo
57  {
58  public:
59 
61 
63  algo();
64 
66 
68  void initialize(const datatools::properties & config_);
69 
71 
73  void run();
74 
76 
78  void reset();
79 
80  private:
81 
82  // Configuration data:
83  bool _debug_;
84  int _max_nloops_;
85  double _epsilon_;
86  std::string _output_filename_;
87 
88  // Working data:
89  bool _initialized_;
90 
91  };
92 
93 } // end of namespace my
94 
95 // OCD support from Bayeux/datatools:
96 #include <datatools/ocd_macros.h>
97 
104 
105 #endif // MY_ALGO_H
A simple configurable algorithm class.
Definition: algo.h:56
DOCD_CLASS_DECLARATION(my::algo)
Declaration of the OCD support for the my::algo class.
User namespace for the algo class.
Definition: algo.cc:16
The Bayeux/datatools library top-level namespace.
Definition: algo.h:13
algo()
Default constructor.
Definition: algo.cc:18
void reset()
Reset the algorithm.
Definition: algo.cc:65
void initialize(const datatools::properties &config_)
Main initialization from a container of configuration parameters.
Definition: algo.cc:28
void run()
Run the algorithm.
Definition: algo.cc:76
A dictionary of arbitrary properties.
Definition: properties.h:125