]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWG2/FEMTOSCOPY/AliFemto/AliFemtoEventReaderESDChain.h
Add AliCentrality support
[u/mrichter/AliRoot.git] / PWG2 / FEMTOSCOPY / AliFemto / AliFemtoEventReaderESDChain.h
1 ////////////////////////////////////////////////////////////////////////////////
2 //                                                                            //
3 // AliFemtoEventReaderESDChain - the reader class for the Alice ESD           //
4 // tailored for the Task framework                                            //
5 // Reads in AliESDfriend to create shared hit/quality information             //
6 // Authors: Adam Kisiel kisiel@mps.ohio-state.edu                             //
7 //                                                                            //
8 ////////////////////////////////////////////////////////////////////////////////
9 #ifndef ALIFEMTOEVENTREADERESDCHAIN_H
10 #define ALIFEMTOEVENTREADERESDCHAIN_H
11
12 #include "AliFemtoEventReader.h"
13 #include "AliFemtoEnumeration.h"
14
15 #include <string>
16 #include <vector>
17 #include "TTree.h"
18 #include "TGraph.h"
19 #include "AliESDEvent.h"
20 #include "AliESDfriend.h"
21 #include "AliPhysicsSelection.h"
22 #include <list>
23
24 class AliFemtoEvent;
25
26 class AliFemtoEventReaderESDChain : public AliFemtoEventReader 
27 {
28  public:
29   enum TrackType {kGlobal=0, kTPCOnly=1, kITSOnly=2, kSPDTracklet=3};
30   typedef enum TrackType ReadTrackType;
31
32   enum EventMult {kTracklet=0, kITSTPC=1, kITSPure=2, kGlobalCount=3, kSPDLayer1=4, kV0Centrality=5 };
33   typedef enum EventMult EstEventMult;
34
35   AliFemtoEventReaderESDChain();
36   AliFemtoEventReaderESDChain(const AliFemtoEventReaderESDChain& aReader);
37   ~AliFemtoEventReaderESDChain();
38
39   AliFemtoEventReaderESDChain& operator=(const AliFemtoEventReaderESDChain& aReader);
40
41   AliFemtoEvent* ReturnHbtEvent();
42   AliFemtoString Report();
43   void SetConstrained(const bool constrained);
44   void SetReadTPCInner(const bool readinner);
45   void SetUseTPCOnly(const bool usetpconly);
46
47   void SetUsePhysicsSelection(const bool usephysics);
48   void SetUseMultiplicity(EstEventMult aType);
49
50   bool GetConstrained() const;
51   bool GetReadTPCInner() const;
52   bool GetUseTPCOnly() const;
53   
54   void SetReadTrackType(ReadTrackType aType);
55
56   void SetESDSource(AliESDEvent *aESD);
57   //  void SetESDfriendSource(AliESDfriend *aFriend);
58
59  protected:
60
61  private:
62   string         fFileName;      //name of current ESD file
63   bool           fConstrained;   //flag to set which momentum from ESD file will be use
64   bool           fReadInner;     // flag to set if one wants to read TPC-only momentum
65                                  // and store it in the hidden info
66   bool           fUseTPCOnly;    // flag to set if one wants to replace the global parameters 
67                                  // by the TPC only ones
68   int            fNumberofEvent; //number of Events in ESD file
69   int            fCurEvent;      //number of current event
70   unsigned int   fCurFile;       //number of current file
71   AliESDEvent*   fEvent;         //ESD event
72   //  AliESDfriend*  fEventFriend;
73   bool           fUsePhysicsSel; //if true the physics selection class will be used
74   AliPhysicsSelection *fSelect;  //Class to select only physics events
75   ReadTrackType  fTrackType;     // Type of track read
76   EstEventMult   fEstEventMult;  // Type of the event multiplicity estimator
77
78 /*   list<Int_t>  **fSharedList;       //! Table (one list per padrow) of clusters which are shared */
79 /*   list<Int_t>  **fClusterPerPadrow; //! Table (one list per padrow) of clusters in each padrow */
80                 
81   Float_t GetSigmaToVertex(double *impact, double *covar);
82
83 #ifdef __ROOT__
84   ClassDef(AliFemtoEventReaderESDChain, 1)
85 #endif
86
87     };
88   
89 #endif
90
91