]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWGCF/FEMTOSCOPY/AliFemto/AliFemtoEventReaderAODChain.cxx
Reaction Plane analysis updates
[u/mrichter/AliRoot.git] / PWGCF / FEMTOSCOPY / AliFemto / AliFemtoEventReaderAODChain.cxx
1 ////////////////////////////////////////////////////////////////////////////////
2 //                                                                            //
3 // AliFemtoEventReaderAODChain - the reader class for the Alice AOD from Chain//
4 // Reads in AOD information and converts it into internal AliFemtoEvent       //
5 // Authors: Adam Kisiel kisiel@mps.ohio-state.edu                             //
6 //                                                                            //
7 ////////////////////////////////////////////////////////////////////////////////
8
9 #include "AliFemtoEventReaderAODChain.h"
10
11 #include "TFile.h"
12 #include "TTree.h"
13 #include "AliAODEvent.h"
14 #include "AliAODTrack.h"
15 #include "AliAODVertex.h"
16
17 #include "AliFmPhysicalHelixD.h"
18 #include "AliFmThreeVectorF.h"
19
20 #include "SystemOfUnits.h"
21
22 #include "AliFemtoEvent.h"
23 #include "AliFemtoModelHiddenInfo.h"
24
25 ClassImp(AliFemtoEventReaderAODChain)
26
27 #if !(ST_NO_NAMESPACES)
28   using namespace units;
29 #endif
30
31 using namespace std;
32 //____________________________
33 //constructor with 0 parameters , look at default settings 
34 AliFemtoEventReaderAODChain::AliFemtoEventReaderAODChain():
35   AliFemtoEventReaderAOD()
36 {
37   // default constructor
38 }
39
40 AliFemtoEventReaderAODChain::AliFemtoEventReaderAODChain(const AliFemtoEventReaderAODChain &aReader) :
41   AliFemtoEventReaderAOD(aReader)
42 {
43   // copy constructor
44 }
45 //__________________
46 //Destructor
47 AliFemtoEventReaderAODChain::~AliFemtoEventReaderAODChain()
48 {
49   // destructor
50 }
51
52 //__________________
53 AliFemtoEventReaderAODChain& AliFemtoEventReaderAODChain::operator=(const AliFemtoEventReaderAODChain& aReader)
54 {
55   // assignment operator
56   if (this == &aReader)
57     return *this;
58
59   *this = aReader;
60
61   return *this;
62 }
63 //__________________
64 AliFemtoString AliFemtoEventReaderAODChain::Report()
65 {
66   // create reader report
67   AliFemtoString temp = "\n This is the AliFemtoEventReaderAODChain\n";
68   return temp;
69 }
70
71 AliFemtoEvent* AliFemtoEventReaderAODChain::ReturnHbtEvent()
72 {
73   // read in a next hbt event from the chain
74   // convert it to AliFemtoEvent and return
75   // for further analysis
76   if (!fEvent) return 0;
77
78   AliFemtoEvent *hbtEvent = 0;
79
80   // Get the PWG2 specific information if it exists
81 //   fPWG2AODTracks = (TClonesArray *) fEvent->GetList()->FindObject("pwg2aodtracks");
82   
83 //   if (fPWG2AODTracks) {
84 //     cout << "Found additional PWG2 specific information in the AOD!" << endl;
85 //     cout << "Reading only tracks with the additional information" << endl;
86 //   }
87
88   // cout<<"starting to read event "<<fCurEvent<<endl;
89         
90   hbtEvent = new AliFemtoEvent;
91
92   CopyAODtoFemtoEvent(hbtEvent);
93
94   fCurEvent++;  
95   return hbtEvent; 
96 }
97
98 //___________________
99 void AliFemtoEventReaderAODChain::SetAODSource(AliAODEvent *aAOD)
100 {
101   // The chain loads the AOD for us
102   // You must provide the address where it can be found
103   fEvent = aAOD;
104 }
105
106
107
108