source: trunk/MagicSoft/Mars/mbase/MEvtLoop.h@ 1516

Last change on this file since 1516 was 1487, checked in by tbretz, 22 years ago
*** empty log message ***
File size: 1.9 KB
Line 
1#ifndef MARS_MEvtLoop
2#define MARS_MEvtLoop
3
4/////////////////////////////////////////////////////////////////////////////
5// //
6// MEvtLoop //
7// //
8// Class to execute the tasks in a tasklist //
9// //
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef MARS_MParContainer
13#include "MParContainer.h"
14#endif
15
16class MParList;
17class MTaskList;
18class TGProgressBar;
19
20class MEvtLoop : public MParContainer
21{
22private:
23 MParList *fParList;
24 MTaskList *fTaskList; //!
25
26 TGProgressBar *fProgress; //!
27
28 enum { kIsOwner = BIT(14) };
29
30 Bool_t HasDuplicateNames(const TString txt) const;
31 Bool_t HasDuplicateNames(TObjArray &arr, const TString txt) const;
32
33public:
34 MEvtLoop();
35 virtual ~MEvtLoop();
36
37 void SetParList(MParList *p) { fParList = p; }
38 MParList *GetParList() const { return fParList; }
39 MTaskList *GetTaskList() const { return fTaskList; }
40
41 void SetOwner(Bool_t enable=kTRUE);
42
43 void SetProgressBar(TGProgressBar *bar) { fProgress = bar; }
44
45 Bool_t PreProcess(const char *tlist="MTaskList");
46 void Process(Int_t maxcnt) const;
47 Bool_t PostProcess() const;
48
49 Bool_t Eventloop(Int_t maxcnt=-1, const char *tlist="MTaskList");
50
51 void MakeMacro(const char *filename="evtloop.C");
52
53 void SavePrimitive(ofstream &out, Option_t *o="");
54
55 Int_t Read(const char *name="Evtloop");
56 Int_t Write(const char *name="Evtloop", Int_t option=0, Int_t bufsize=0);
57
58 void Print(Option_t *opt="") const;
59
60 ClassDef(MEvtLoop, 1) // Class to execute the tasks in a tasklist
61};
62
63R__EXTERN TList *gListOfPrimitives; // instantiation in MEvtLoop
64
65#endif
Note: See TracBrowser for help on using the repository browser.