/home/docs/checkouts/readthedocs.org/user_builds/ratpac/checkouts/latest/src/core/include/RAT/ProducerBlock.hh Source File

Ratpac-two: /home/docs/checkouts/readthedocs.org/user_builds/ratpac/checkouts/latest/src/core/include/RAT/ProducerBlock.hh Source File
Ratpac-two
ProducerBlock.hh
1 #ifndef __RAT_ProducerBlock__
2 #define __RAT_ProducerBlock__
3 
4 #include <RAT/ProcBlock.hh>
5 #include <RAT/Producer.hh>
6 #include <vector>
7 
8 namespace RAT {
9 
10 class ProcBlock;
11 
13  public:
15  ProducerBlock();
16  virtual ~ProducerBlock();
17 
18  void Init(ProcBlock *theMainBlock);
19  virtual void BeginOfRun(DS::Run *run);
20  virtual void EndOfRun(DS::Run *run);
21  virtual void Clear();
22 
23  template <class T>
24  static void AppendProducer() {
25  fProducerList.push_back(new T(mainBlock));
26  }
27 
28  static std::vector<Producer *> fProducerList;
29  static ProcBlock *mainBlock;
30 };
31 
32 } // namespace RAT
33 
34 #endif
Definition: Run.hh:22
Definition: ProcBlock.hh:33
Definition: ProducerBlock.hh:12
ProducerBlock()
Definition: ProducerBlock.cc:12
Definition: CCCrossSecMessenger.hh:29