]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWG2/FLOW/AliSelectorFoF.h
namespace added for constants
[u/mrichter/AliRoot.git] / PWG2 / FLOW / AliSelectorFoF.h
1 /* Id: AliSelectorFoF.h, v1.1 01/02/2007 esimili Exp */
2 /* derived from AliSelector.h,v 1.10 2006/08/15 jgrosseo Exp */
3
4 // This selector is only dependent on the ESD library, if you need the whole of AliROOT use AliSelectorRL
5 #ifndef ALISELECTORFOF_H
6 #define ALISELECTORFOF_H
7
8 #include <TSelector.h>
9 #include "AliFlowConstants.h"
10
11 class AliFlowEvent;
12 class AliFlowSelection;
13 class AliFlowMaker;
14 class AliFlowAnalyser; 
15 class AliFlowWeighter;
16
17 class AliESD;
18 class AliESDtrack;
19 class AliESDv0;
20
21 class TFile;
22 class TTree;
23 class TString;
24
25 class AliSelectorFoF : public TSelector {
26
27
28   public:
29
30     AliSelectorFoF();
31     virtual ~AliSelectorFoF();
32
33    // defalt AliSelector things
34     virtual Int_t   Version() const {return 1;}
35     virtual void    Begin(TTree*);
36     virtual void    SlaveBegin(TTree* tree);
37     virtual void    Init(TTree *tree);
38     virtual Bool_t  Notify();
39     virtual Bool_t  Process(Long64_t entry);
40     virtual void    SlaveTerminate();
41     virtual void    Terminate();
42
43   // output file name
44     void            SetFlowEventFileName(TString name)    { fFlowEventFileName = name ; }
45     void            SetFlowWeightFileName(TString name)   { fFlowWgtFileName = name ; }
46     void            SetFlowAnalysisFileName(TString name) { fFlowAnalysisFileName = name ; }
47     TString         GetFlowEventFileName()                { return fFlowEventFileName ; }
48     TString         GetFlowWeightFileName()               { return fFlowWgtFileName ; } 
49     TString         GetFlowAnalysisFileName()             { return fFlowAnalysisFileName ; } 
50
51   // tasks
52     void            SetDoNothing(Bool_t kt = kTRUE)      { fDoNothing = kt ; }
53     void            SetSaveFlowEvents(Bool_t kt = kTRUE) { fSaveFlowEvents = kt ; }
54     void            SetOnFlyAnalysis(Bool_t kt = kTRUE)  { fOnFlyAnalysis = kt ; }
55     void            SetOnFlyWeight(Bool_t kt = kTRUE)    { fOnFlyWeight = kt ; }
56
57
58  protected:
59   
60     TTree         *fTree;                 //! pointer to the TTree containing the events
61     AliESD*       fESD;                   //! "ESD" branch in fChain
62     Int_t         fCountFiles ;           //! number of processed file
63
64   // output file names
65     TString       fFlowEventFileName;     //! AliFlowEvents file 
66     TString       fFlowAnalysisFileName;  //! Analysis Histograms file
67     TString       fFlowWgtFileName;       //! Weights file
68
69   // defalt AliSelector things
70     TTree*        GetKinematics();
71     void          CheckOptions();
72
73
74  private:
75
76   // flow things
77     TFile*            fFlowfile ;         //! pointer to flow event file
78     TFile*            fFlowWgtFile ;      //! pointer to flow weight file
79     AliFlowEvent*     fFlowEvent ;        //! pointer to flow event
80     AliFlowSelection* fFlowSelect;        //! pointer to flow selection
81     AliFlowMaker*     fFlowMaker ;        //! flow evt maker
82     AliFlowWeighter*  fFlowWeighter ;     //! flow phi weights
83     AliFlowAnalyser*  fFlowAnal ;         //! flow analysis
84
85   // enumerators                                  
86     Int_t             fRunID;             //! last run ID
87     Int_t             fEventNumber ;      //! progressive enumeration of ESD events
88     Int_t             fNumberOfTracks ;   //! progressive enumeration of ESD tracks
89     Int_t             fNumberOfV0s ;      //! progressive enumeration of ESD V0
90     Int_t             fNumberOfEvents ;   //! total number of ESD events in file
91  
92   // Flags
93     Bool_t            fDoNothing ;        //! flag for a dummy execution 
94     Bool_t            fSaveFlowEvents ;   //! flag for saving the flow events 
95     Bool_t            fOnFlyAnalysis ;    //! flag for on-fly analysis 
96     Bool_t            fOnFlyWeight ;      //! flag for on-fly analysis 
97
98   // defalt AliSelector things
99     void              DeleteKinematicsFile();
100     TFile*            fKineFile;          //! pointer to Kinematics.root if the file was opened
101
102   // to make the code checker happy
103     AliSelectorFoF(const AliSelectorFoF&);
104     AliSelectorFoF& operator=(const AliSelectorFoF&);
105
106   ClassDef(AliSelectorFoF,0);
107 };
108
109 #endif