]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWGHF/correlationHF/AliDxHFEParticleSelectionEl.h
Dictionary generation for par file compilation requires to replace forward declaratio...
[u/mrichter/AliRoot.git] / PWGHF / correlationHF / AliDxHFEParticleSelectionEl.h
1 //-*- Mode: C++ -*-
2 // $Id$
3
4 //* This file is property of and copyright by the ALICE Project        * 
5 //* ALICE Experiment at CERN, All rights reserved.                     *
6 //* See cxx source for full Copyright notice                           *
7
8 /// @file   AliDxHFEParticleSelectionEl.h
9 /// @author Sedat Altinpinar, Hege Erdal, Matthias Richter
10 /// @date   2012-03-19
11 /// @brief  Electron selection for D-HFE correlations
12 ///
13
14 #ifndef ALIDXHFEPARTICLESELECTIONEL_H
15 #define ALIDXHFEPARTICLESELECTIONEL_H
16
17 #include "AliDxHFEParticleSelection.h"
18
19
20 // 2012-09-17: there has been a problem in the dictionary generation for par file
21 // compilation, so we have to include the header files indicated below
22 //  Generating dictionary ...
23 //  In file included from $ROOTSYS/include/TObject.h:230:0,
24 //                   from G__PWGHFcorrelationHF.h:32,
25 //                   from G__PWGHFcorrelationHF.cxx:17:
26 //  $ROOTSYS/include/TBuffer.h: In function ‘TBuffer& operator>>(TBuffer&, Tmpl*&) [with Tmpl = AliHFEcuts]’:
27 //  G__PWGHFcorrelationHF.cxx:1658:15:   instantiated from here
28 //  $ROOTSYS/include/TBuffer.h:373:47: error: invalid use of incomplete type ‘struct AliHFEcuts’
29 //  correlationHF/AliDxHFEParticleSelectionEl.h:25:7: error: forward declaration of ‘struct AliHFEcuts’
30 #include "AliHFEcuts.h" // need to directly include to avoid compilation error in the dictionary
31 #include "AliHFEpid.h"  // need to directly include to avoid compilation error in the dictionary
32
33 class AliPID;
34 class AliPIDResponse;
35 class AliHFEvarManager;
36 class AliHFEpidBase;
37 class AliHFEtools;
38 class AliVEvent;
39 class AliCFManager;
40 class TH1;
41
42 /**
43  * @class AliDxHFEParticleSelectionEl
44  * Electron selection for D-HFE correlations, implements the specific
45  * selection criteria.
46  */
47 class AliDxHFEParticleSelectionEl : public AliDxHFEParticleSelection {
48   public:
49   /// constructor
50   AliDxHFEParticleSelectionEl(const char* opt="");
51   /// destructor
52   virtual ~AliDxHFEParticleSelectionEl();
53
54   enum {
55     kCutHFE = 0,
56     kCutPID = 1,
57     kNCuts
58   };
59
60   enum {
61     kRecKineITSTPC=0,
62     kRecPrim,
63     kHFEcutsITS,
64     kHFEcutsTOF,
65     kHFEcutsTPC,
66     kPID,
67     kSelected,
68     kNCutLabels
69   };
70
71   ///overloaded from AliDxHFEParticleSelection: Init
72   virtual int Init();
73
74   /// overloaded from AliDxHFEParticleSelection: init the control objects
75   virtual int InitControlObjects();
76   virtual THnSparse* DefineTHnSparse() const;
77
78   /// overloaded from AliDxHFEParticleSelection: check particle
79   virtual int IsSelected(AliVParticle* p, const AliVEvent* pEvent);
80
81   virtual int HistogramParticleProperties(AliVParticle* p, int selected);
82
83   // TODO: function can be renamed to better describe what it's doing
84   virtual int DefineParticleProperties(AliVParticle* p, Double_t* date, int dimension) const;
85
86   /// set cuts object: a type cast check is implemented in the method
87   virtual void SetCuts(TObject* /*cuts*/, int /*level*/=0);
88
89  protected:
90
91  private:
92   /// copy contructor prohibited
93   AliDxHFEParticleSelectionEl(const AliDxHFEParticleSelectionEl&);
94   /// assignment operator prohibited
95   AliDxHFEParticleSelectionEl& operator=(const AliDxHFEParticleSelectionEl&);
96
97   /// check cut of specified step, e.g.
98   bool ProcessCutStep(Int_t cutStep, AliVParticle *track);
99
100   AliHFEpid*    fPID;                //! the PID object
101   THnSparse*    fElectronProperties; // the particle properties of selected particles
102   TH1*          fWhichCut;           // effective cut for a rejected particle
103   AliHFEcuts*   fCuts;               //! Cuts for HF electrons
104   AliCFManager* fCFM;                //! Correction Framework Manager
105
106   static const char* fgkTrackControlBinNames[]; //! bin labels for track control histogram
107   static const char* fgkCutBinNames[]; //! bin labels for cuts histogram
108
109   ClassDef(AliDxHFEParticleSelectionEl, 2);
110 };
111
112 #endif