]>
Commit | Line | Data |
---|---|---|
c865cb1d | 1 | #ifndef ALIRSNLOOP_H |
2 | #define ALIRSNLOOP_H | |
3 | ||
4 | // | |
b63357a0 | 5 | // Base class to implement any computation within the RSN package. |
61f275d1 | 6 | // It contains only an array of output objects which must derive |
b63357a0 | 7 | // from AliRsnOutput. |
61f275d1 | 8 | // Its core functions ar Init() and DoLoop() which must be |
b63357a0 | 9 | // overloaded by any class which inherits from this. |
c865cb1d | 10 | // |
11 | ||
12 | #include "TNamed.h" | |
13 | #include "TObjArray.h" | |
14 | ||
15 | #include "AliRsnListOutput.h" | |
16 | #include "AliRsnValue.h" | |
17 | #include "AliRsnCutSet.h" | |
18 | ||
19 | class TList; | |
20 | class AliRsnEvent; | |
21 | class AliRsnListOutput; | |
22 | class AliRsnDaughterSelector; | |
23 | ||
24 | class AliRsnLoop : public TNamed { | |
25 | public: | |
26 | ||
27 | enum EOut { | |
28 | kH1, | |
29 | kHSparse, | |
30 | kNtuple | |
31 | }; | |
32 | ||
33 | AliRsnLoop(const char *name = "default", Bool_t isMixed = kFALSE); | |
34 | AliRsnLoop(const AliRsnLoop ©); | |
61f275d1 | 35 | AliRsnLoop &operator=(const AliRsnLoop ©); |
c865cb1d | 36 | ~AliRsnLoop(); |
61f275d1 | 37 | |
c865cb1d | 38 | void SetMixed(Bool_t yn = kTRUE) {fIsMixed = yn;} |
39 | void SetEventCuts(AliRsnCutSet *set) {fEventCuts = set;} | |
40 | Bool_t IsMixed() const {return fIsMixed;} | |
61f275d1 | 41 | AliRsnCutSet *GetEventCuts() {return fEventCuts;} |
c865cb1d | 42 | Bool_t OkEvent(AliRsnEvent *rsn); |
61f275d1 | 43 | |
c865cb1d | 44 | virtual void AddOutput(TObject *output); |
45 | virtual void Print(Option_t *option = "") const; | |
46 | virtual Bool_t Init(const char *prefix, TList *list); | |
47 | virtual Int_t DoLoop(AliRsnEvent *main, AliRsnDaughterSelector *smain, AliRsnEvent *mix = 0, AliRsnDaughterSelector *smix = 0); | |
48 | ||
49 | protected: | |
50 | ||
51 | Bool_t fIsMixed; // flag to know if the loop works with event mixing | |
52 | AliRsnCutSet *fEventCuts; // event cuts | |
53 | TClonesArray fOutputs; // output object definitions | |
54 | ||
55 | private: | |
56 | ||
57 | ClassDef(AliRsnLoop, 1) | |
58 | }; | |
59 | ||
60 | #endif |