]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWG2/RESONANCES/AliRsnMonitor.h
Add new version of macros for RSN analysis
[u/mrichter/AliRoot.git] / PWG2 / RESONANCES / AliRsnMonitor.h
1 //
2 // *** Class AliRsnMonitor ***
3 //
4 // TODO
5 //
6 // authors: A. Pulvirenti (email: alberto.pulvirenti@ct.infn.it)
7 //          M. Vala (email: martin.vala@cern.ch)
8 //
9
10 #ifndef ALIRSNMonitor_H
11 #define ALIRSNMonitor_H
12
13 #include "TNamed.h"
14
15 #include "AliRsnDaughter.h"
16 #include "AliRsnDaughterDef.h"
17 #include "AliRsnCutSet.h"
18
19 class AliRsnMonitor : public TNamed {
20 public:
21
22    AliRsnMonitor(const char *name = "default", AliRsnDaughterDef *def = 0);
23    AliRsnMonitor(const AliRsnMonitor &copy);
24    AliRsnMonitor& operator=(const AliRsnMonitor&);
25    ~AliRsnMonitor();
26    
27    // getters
28    Bool_t             IsOnlyTrue()   const {return fOnlyTrue;}
29    Int_t              GetCount()     const {return fCount;}
30    AliRsnDaughterDef* GetDaughterDef()     {return fDaughterDef;}
31    AliRsnCutSet*      GetCuts()            {return &fCuts;}
32    AliRsnDaughter*    GetDaughter()        {return fDaughter;}
33    
34    // setters (not for all members)
35    void               SetOnlyTrue(Bool_t onlyTrue = kTRUE) {fOnlyTrue = onlyTrue;}
36    void               SetCount(Int_t count)                {fCount = count;}
37    void               ResetCount()                         {fCount = 0;}
38    
39    // methods
40    Bool_t             Fill(AliRsnDaughter *d);
41    virtual void       Print(Option_t *option = "") const;
42    virtual void       Compute();
43    virtual void       Init(const char *prefix, TList *list);
44
45 protected:
46
47    Bool_t             fOnlyTrue;        //  select true Monitors only?
48    Int_t              fCount;           //  counter incremented for each added Monitor
49
50    AliRsnDaughterDef *fDaughterDef;     //  Monitor definition (particles, charges)
51    AliRsnCutSet       fCuts;            //  collection of all cuts
52    AliRsnDaughter    *fDaughter;        //! pointer to daughter
53
54 private:
55
56    ClassDef(AliRsnMonitor, 2)
57 };
58
59 #endif
60