AliPhysics  32e057f (32e057f)
AliDalitzElectronSelector.h
Go to the documentation of this file.
1 #ifndef ALIDALITZELECTRONSELECTOR_H
2 #define ALIDALITZELECTRONSELECTOR_H
3 
4 #include "AliAnalysisTaskSE.h"
5 #include "AliAODv0.h"
6 #include "AliESDv0.h"
8 #include "AliExternalTrackParam.h"
9 
10 class TRandom3;
11 class TList;
12 class TString;
13 class TH1F;
14 class TH2F;
15 
16 using namespace std;
17 
19 
20  public:
21 
22  AliDalitzElectronSelector(const char *name="ElectronSelector");
23  //Uncopyable & operator=(const Uncopyable&);
24 
25  virtual ~AliDalitzElectronSelector(); //virtual destructor
26  void UserCreateOutputObjects();
27 
28  virtual void UserExec(Option_t *option);
29  virtual void Terminate(Option_t *);
30  virtual void Init();
31 
32  Bool_t ProcessEvent(AliVEvent *inputEvent,AliMCEvent *mcEvent=NULL);
33  Bool_t IsEventSelected(){return fEventIsSelected;}
34 
35  // Return selected electron/positron array
36  vector <Int_t> GetReconstructedElectronsIndex(){ return fElectronsIndex; }
37  vector <Int_t> GetReconstructedPositronsIndex(){ return fPositronsIndex; }
38  AliDalitzElectronCuts *GetDalitzElectronCuts(){ return fElectronCuts; }
39  TList *GetCutHistograms(){ if(fElectronCuts){return fElectronCuts->GetCutHistograms();} return NULL;}
40  // Set Options
41 
42  void SetDalitzElectronCuts(const TString cut);
43  void SetDalitzElectronCuts(AliDalitzElectronCuts *cuts){fElectronCuts=cuts;}
44 
45  protected:
46  //selected electron arrays
47 
48  Bool_t ProcessESDs();
49  AliDalitzElectronCuts *fElectronCuts; // Pointer to the ConversionCut Selection
50  vector<Int_t> fPositronsIndex;
51  vector<Int_t> fElectronsIndex;
53 
54  private:
55  AliDalitzElectronSelector (const AliDalitzElectronSelector&); // not implemented
56  AliDalitzElectronSelector & operator=(const AliDalitzElectronSelector&); // not implemented
57 
58 
59 
60  ClassDef(AliDalitzElectronSelector,1)
61  };
62 
64  if(fElectronCuts != NULL){
65  delete fElectronCuts;
66  fElectronCuts=NULL;
67  }
68  if(fElectronCuts == NULL){
69  fElectronCuts=new AliDalitzElectronCuts("ElectronCuts","ElectronCuts");
70  fElectronCuts->InitializeCutsFromCutString(cut.Data());
71  }
72 }
73 
74 
75 #endif
Definition: External.C:236
vector< Int_t > GetReconstructedPositronsIndex()
vector< Int_t > GetReconstructedElectronsIndex()
void SetDalitzElectronCuts(AliDalitzElectronCuts *cuts)
AliDalitzElectronCuts * GetDalitzElectronCuts()
const char Option_t
Definition: External.C:48
AliDalitzElectronCuts * fElectronCuts
bool Bool_t
Definition: External.C:53
void SetDalitzElectronCuts(const TString cut)