]>
Commit | Line | Data |
---|---|---|
9da38871 | 1 | // -*- mode: C++ -*- |
af7ba10c | 2 | #ifndef ALIESD_H |
3 | #define ALIESD_H | |
8a8d023f | 4 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * |
5 | * See cxx source for full Copyright notice */ | |
6 | ||
88cb7938 | 7 | |
8 | /* $Id$ */ | |
9 | ||
ae982df3 | 10 | //------------------------------------------------------------------------- |
11 | // Class AliESD | |
12 | // This is the class to deal with during the physical analysis of data | |
13 | // | |
14 | // Origin: Iouri Belikov, CERN, Jouri.Belikov@cern.ch | |
15 | //------------------------------------------------------------------------- | |
8a8d023f | 16 | |
af7ba10c | 17 | #include <TClonesArray.h> |
18 | #include <TObject.h> | |
19 | ||
af7ba10c | 20 | #include "AliESDMuonTrack.h" |
21 | #include "AliESDPmdTrack.h" | |
0ee00e25 | 22 | #include "AliESDTrdTrack.h" |
af7ba10c | 23 | #include "AliESDVertex.h" |
24 | #include "AliESDcascade.h" | |
51ad6848 | 25 | #include "AliESDkink.h" |
af7ba10c | 26 | #include "AliESDtrack.h" |
482070f2 | 27 | #include "AliESDHLTtrack.h" |
85c60a8e | 28 | #include "AliESDCaloCluster.h" |
af7ba10c | 29 | #include "AliESDv0.h" |
51ad6848 | 30 | #include "AliESDV0MI.h" |
9da38871 | 31 | #include "AliESDFMD.h" |
8a8d023f | 32 | |
d75007f6 | 33 | class AliESDfriend; |
34 | ||
ae982df3 | 35 | class AliESD : public TObject { |
8a8d023f | 36 | public: |
ae982df3 | 37 | AliESD(); |
af7ba10c | 38 | virtual ~AliESD(); |
8a8d023f | 39 | |
d75007f6 | 40 | void SetESDfriend(const AliESDfriend *f); |
41 | void GetESDfriend(AliESDfriend *f) const; | |
42 | ||
ae982df3 | 43 | void SetEventNumber(Int_t n) {fEventNumber=n;} |
5121f0b3 | 44 | void SetRunNumber(Int_t n) {fRunNumber=n;} |
2257f27e | 45 | void SetTrigger(Long_t n) {fTrigger=n;} |
a866ac60 | 46 | void SetMagneticField(Float_t mf){fMagneticField = mf;} |
47 | Float_t GetMagneticField() const {return fMagneticField;} | |
48 | ||
873f1f73 | 49 | AliESDtrack *GetTrack(Int_t i) const { |
ae982df3 | 50 | return (AliESDtrack *)fTracks.UncheckedAt(i); |
51 | } | |
482070f2 | 52 | AliESDHLTtrack *GetHLTConfMapTrack(Int_t i) const { |
53 | return (AliESDHLTtrack *)fHLTConfMapTracks.UncheckedAt(i); | |
54 | } | |
55 | AliESDHLTtrack *GetHLTHoughTrack(Int_t i) const { | |
56 | return (AliESDHLTtrack *)fHLTHoughTracks.UncheckedAt(i); | |
57 | } | |
873f1f73 | 58 | AliESDMuonTrack *GetMuonTrack(Int_t i) const { |
672b5f43 | 59 | return (AliESDMuonTrack *)fMuonTracks.UncheckedAt(i); |
60 | } | |
561b7b31 | 61 | AliESDPmdTrack *GetPmdTrack(Int_t i) const { |
62 | return (AliESDPmdTrack *)fPmdTracks.UncheckedAt(i); | |
63 | } | |
0ee00e25 | 64 | AliESDTrdTrack *GetTrdTrack(Int_t i) const { |
65 | return (AliESDTrdTrack *)fTrdTracks.UncheckedAt(i); | |
66 | } | |
672b5f43 | 67 | |
51ad6848 | 68 | Int_t AddTrack(const AliESDtrack *t) { |
69 | AliESDtrack * track = new(fTracks[fTracks.GetEntriesFast()]) AliESDtrack(*t); | |
70 | track->SetID(fTracks.GetEntriesFast()-1); | |
71 | return track->GetID(); | |
72 | ||
ae982df3 | 73 | } |
482070f2 | 74 | void AddHLTConfMapTrack(const AliESDHLTtrack *t) { |
75 | new(fHLTConfMapTracks[fHLTConfMapTracks.GetEntriesFast()]) AliESDHLTtrack(*t); | |
76 | } | |
77 | void AddHLTHoughTrack(const AliESDHLTtrack *t) { | |
78 | new(fHLTHoughTracks[fHLTHoughTracks.GetEntriesFast()]) AliESDHLTtrack(*t); | |
79 | } | |
672b5f43 | 80 | void AddMuonTrack(const AliESDMuonTrack *t) { |
81 | new(fMuonTracks[fMuonTracks.GetEntriesFast()]) AliESDMuonTrack(*t); | |
82 | } | |
561b7b31 | 83 | void AddPmdTrack(const AliESDPmdTrack *t) { |
84 | new(fPmdTracks[fPmdTracks.GetEntriesFast()]) AliESDPmdTrack(*t); | |
85 | } | |
0ee00e25 | 86 | void AddTrdTrack(const AliESDTrdTrack *t) { |
87 | new(fTrdTracks[fTrdTracks.GetEntriesFast()]) AliESDTrdTrack(*t); | |
88 | } | |
8a8d023f | 89 | |
873f1f73 | 90 | AliESDv0 *GetV0(Int_t i) const { |
e23730c7 | 91 | return (AliESDv0 *)fV0s.UncheckedAt(i); |
92 | } | |
93 | void AddV0(const AliESDv0 *v) { | |
94 | new(fV0s[fV0s.GetEntriesFast()]) AliESDv0(*v); | |
95 | } | |
51ad6848 | 96 | void UpdateV0PIDs(); |
e23730c7 | 97 | |
873f1f73 | 98 | AliESDcascade *GetCascade(Int_t i) const { |
e23730c7 | 99 | return (AliESDcascade *)fCascades.UncheckedAt(i); |
100 | } | |
101 | void AddCascade(const AliESDcascade *c) { | |
102 | new(fCascades[fCascades.GetEntriesFast()]) AliESDcascade(*c); | |
103 | } | |
104 | ||
51ad6848 | 105 | AliESDkink *GetKink(Int_t i) const { |
106 | return (AliESDkink *)fKinks.UncheckedAt(i); | |
107 | } | |
108 | Int_t AddKink(const AliESDkink *c) { | |
109 | AliESDkink * kink = new(fKinks[fKinks.GetEntriesFast()]) AliESDkink(*c); | |
110 | kink->SetID(fKinks.GetEntriesFast()); | |
111 | return fKinks.GetEntriesFast()-1; | |
112 | } | |
113 | ||
114 | AliESDV0MI *GetV0MI(Int_t i) const { | |
115 | return (AliESDV0MI *)fV0MIs.UncheckedAt(i); | |
116 | } | |
117 | Int_t AddV0MI(const AliESDV0MI *c) { | |
118 | AliESDV0MI * v0 = new(fV0MIs[fV0MIs.GetEntriesFast()]) AliESDV0MI(*c); | |
119 | v0->SetID(fV0MIs.GetEntriesFast()-1); | |
120 | return fV0MIs.GetEntriesFast()-1; | |
121 | } | |
122 | ||
85c60a8e | 123 | AliESDCaloCluster *GetCaloCluster(Int_t i) const { |
124 | return (AliESDCaloCluster *)fCaloClusters.UncheckedAt(i); | |
125 | } | |
126 | Int_t AddCaloCluster(const AliESDCaloCluster *c) { | |
127 | AliESDCaloCluster *clus = new(fCaloClusters[fCaloClusters.GetEntriesFast()]) AliESDCaloCluster(*c); | |
128 | clus->SetID(fCaloClusters.GetEntriesFast()-1); | |
129 | return fCaloClusters.GetEntriesFast()-1; | |
130 | } | |
131 | ||
1f46a9ae | 132 | void SetVertex(const AliESDVertex* vertex) { |
2257f27e | 133 | new(&fPrimaryVertex) AliESDVertex(*vertex); |
134 | } | |
135 | const AliESDVertex* GetVertex() const {return &fPrimaryVertex;}; | |
873f1f73 | 136 | |
ae982df3 | 137 | Int_t GetEventNumber() const {return fEventNumber;} |
138 | Int_t GetRunNumber() const {return fRunNumber;} | |
139 | Long_t GetTrigger() const {return fTrigger;} | |
8a8d023f | 140 | |
672b5f43 | 141 | Int_t GetNumberOfTracks() const {return fTracks.GetEntriesFast();} |
482070f2 | 142 | Int_t GetNumberOfHLTConfMapTracks() const {return fHLTConfMapTracks.GetEntriesFast();} |
143 | Int_t GetNumberOfHLTHoughTracks() const {return fHLTHoughTracks.GetEntriesFast();} | |
672b5f43 | 144 | Int_t GetNumberOfMuonTracks() const {return fMuonTracks.GetEntriesFast();} |
561b7b31 | 145 | Int_t GetNumberOfPmdTracks() const {return fPmdTracks.GetEntriesFast();} |
0ee00e25 | 146 | Int_t GetNumberOfTrdTracks() const {return fTrdTracks.GetEntriesFast();} |
e23730c7 | 147 | Int_t GetNumberOfV0s() const {return fV0s.GetEntriesFast();} |
148 | Int_t GetNumberOfCascades() const {return fCascades.GetEntriesFast();} | |
51ad6848 | 149 | Int_t GetNumberOfKinks() const {return fKinks.GetEntriesFast();} |
150 | Int_t GetNumberOfV0MIs() const {return fV0MIs.GetEntriesFast();} | |
85c60a8e | 151 | Int_t GetNumberOfCaloClusters() const {return fCaloClusters.GetEntriesFast();} |
152 | ||
153 | Int_t GetNumberOfEMCALClusters() const {return fEMCALClusters;} | |
154 | void SetNumberOfEMCALClusters(Int_t clus) {fEMCALClusters = clus;} | |
155 | Int_t GetFirstEMCALCluster() const {return fFirstEMCALCluster;} | |
156 | void SetFirstEMCALCluster(Int_t index) {fFirstEMCALCluster = index;} | |
157 | ||
158 | Int_t GetNumberOfPHOSClusters() const {return fPHOSClusters;} | |
159 | void SetNumberOfPHOSClusters(Int_t part) { fPHOSClusters = part ; } | |
160 | void SetFirstPHOSCluster(Int_t index) { fFirstPHOSCluster = index ; } | |
161 | Int_t GetFirstPHOSCluster() const { return fFirstPHOSCluster ; } | |
a2882fb4 | 162 | |
4a78b8c5 | 163 | Float_t GetT0zVertex() const {return fT0zVertex;} |
164 | void SetT0zVertex(Float_t z) {fT0zVertex=z;} | |
6d45eaef | 165 | Float_t GetT0() const {return fT0timeStart;} |
166 | void SetT0(Float_t timeStart) {fT0timeStart = timeStart;} | |
167 | const Float_t * GetT0time() const {return fT0time;} | |
168 | void SetT0time(Float_t time[24]) { | |
169 | for (Int_t i=0; i<24; i++) fT0time[i] = time[i]; | |
170 | } | |
171 | const Float_t * GetT0amplitude() const {return fT0amplitude;} | |
172 | void SetT0amplitude(Float_t amp[24]) { | |
173 | for (Int_t i=0; i<24; i++) fT0amplitude[i] = amp[i]; | |
174 | } | |
ef278eae | 175 | |
32a5cab4 | 176 | Float_t GetZDCN1Energy() const {return fZDCN1Energy;} |
177 | Float_t GetZDCP1Energy() const {return fZDCP1Energy;} | |
178 | Float_t GetZDCN2Energy() const {return fZDCN2Energy;} | |
179 | Float_t GetZDCP2Energy() const {return fZDCP2Energy;} | |
878bc0c2 | 180 | Float_t GetZDCEMEnergy() const {return fZDCEMEnergy;} |
181 | Int_t GetZDCParticipants() const {return fZDCParticipants;} | |
32a5cab4 | 182 | void SetZDC(Float_t n1Energy, Float_t p1Energy, Float_t emEnergy, |
183 | Float_t n2Energy, Float_t p2Energy, Int_t participants) | |
184 | {fZDCN1Energy=n1Energy; fZDCP1Energy=p1Energy; fZDCEMEnergy=emEnergy; | |
185 | fZDCN2Energy=n2Energy; fZDCP2Energy=p2Energy; fZDCParticipants=participants;} | |
878bc0c2 | 186 | |
50ca5f39 | 187 | void ResetV0s() { fV0s.Clear(); } |
188 | void ResetCascades() { fCascades.Clear(); } | |
189 | void Reset(); | |
bf25155c | 190 | |
ef278eae | 191 | void Print(Option_t *option="") const; |
9da38871 | 192 | |
193 | void SetFMDData(AliESDFMD * obj) { | |
194 | fESDFMD = new AliESDFMD(*obj); | |
195 | } | |
196 | ||
197 | AliESDFMD * GetFMDData(){ return fESDFMD;} | |
ef278eae | 198 | |
8a8d023f | 199 | protected: |
200 | ||
201 | // Event Identification | |
ae982df3 | 202 | Int_t fEventNumber; // Event Number |
203 | Int_t fRunNumber; // Run Number | |
204 | Long_t fTrigger; // Trigger Type | |
205 | Int_t fRecoVersion; // Version of reconstruction | |
a866ac60 | 206 | Float_t fMagneticField; // Solenoid Magnetic Field in kG : for compatibility with AliMagF |
8a8d023f | 207 | |
32a5cab4 | 208 | Float_t fZDCN1Energy; // reconstructed energy in the neutron ZDC |
209 | Float_t fZDCP1Energy; // reconstructed energy in the proton ZDC | |
210 | Float_t fZDCN2Energy; // reconstructed energy in the neutron ZDC | |
211 | Float_t fZDCP2Energy; // reconstructed energy in the proton ZDC | |
878bc0c2 | 212 | Float_t fZDCEMEnergy; // reconstructed energy in the electromagnetic ZDC |
213 | Int_t fZDCParticipants; // number of participants estimated by the ZDC | |
214 | ||
4a78b8c5 | 215 | Float_t fT0zVertex; // vertex z position estimated by the START |
6d45eaef | 216 | Float_t fT0timeStart; // interaction time estimated by the START |
217 | Float_t fT0time[24]; // best TOF on each START PMT | |
218 | Float_t fT0amplitude[24]; // number of particles(MIPs) on each START PMT | |
8bbc564d | 219 | AliESDVertex fPrimaryVertex; // Primary vertex estimated by the ITS |
220 | ||
221 | TClonesArray fTracks; // ESD tracks | |
222 | TClonesArray fHLTConfMapTracks;// HLT ESD tracks from Conformal Mapper method | |
223 | TClonesArray fHLTHoughTracks; // HLT ESD tracks from Hough Transform method | |
224 | TClonesArray fMuonTracks; // MUON ESD tracks | |
225 | TClonesArray fPmdTracks; // PMD ESD tracks | |
0ee00e25 | 226 | TClonesArray fTrdTracks; // TRD ESD tracks (triggered) |
8bbc564d | 227 | TClonesArray fV0s; // V0 vertices |
228 | TClonesArray fCascades; // Cascade vertices | |
51ad6848 | 229 | TClonesArray fKinks; // Kinks |
230 | TClonesArray fV0MIs; // V0MI | |
85c60a8e | 231 | TClonesArray fCaloClusters; // Calorimeter clusters for PHOS/EMCAL |
232 | Int_t fEMCALClusters; // Number of EMCAL clusters (subset of caloclusters) | |
233 | Int_t fFirstEMCALCluster; // First EMCAL cluster in the fCaloClusters list | |
234 | ||
235 | Int_t fPHOSClusters; // Number of PHOS clusters (subset of caloclusters) | |
236 | Int_t fFirstPHOSCluster; // First PHOS cluster in the fCaloClusters list | |
704be597 | 237 | |
9da38871 | 238 | AliESDFMD * fESDFMD; // FMD object containing rough multiplicity |
239 | ||
240 | ClassDef(AliESD,9) //ESD class | |
8a8d023f | 241 | }; |
8a8d023f | 242 | #endif |
243 |