]>
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" |
9da38871 | 30 | #include "AliESDFMD.h" |
dd735cf0 | 31 | #include "AliESDVZERO.h" |
32e449be | 32 | #include "AliMultiplicity.h" |
8a8d023f | 33 | |
d75007f6 | 34 | class AliESDfriend; |
35 | ||
ae982df3 | 36 | class AliESD : public TObject { |
8a8d023f | 37 | public: |
ae982df3 | 38 | AliESD(); |
af7ba10c | 39 | virtual ~AliESD(); |
8a8d023f | 40 | |
d75007f6 | 41 | void SetESDfriend(const AliESDfriend *f); |
42 | void GetESDfriend(AliESDfriend *f) const; | |
43 | ||
ae982df3 | 44 | void SetEventNumber(Int_t n) {fEventNumber=n;} |
5121f0b3 | 45 | void SetRunNumber(Int_t n) {fRunNumber=n;} |
001397cd | 46 | void SetTimeStamp(UInt_t timeStamp){fTimeStamp = timeStamp;} |
47 | void SetEventType(UInt_t eventType){fEventType = eventType;} | |
b647652d | 48 | void SetTriggerMask(ULong64_t n) {fTriggerMask=n;} |
49 | void SetTriggerCluster(UChar_t n) {fTriggerCluster = n;} | |
a866ac60 | 50 | void SetMagneticField(Float_t mf){fMagneticField = mf;} |
51 | Float_t GetMagneticField() const {return fMagneticField;} | |
52 | ||
873f1f73 | 53 | AliESDtrack *GetTrack(Int_t i) const { |
ae982df3 | 54 | return (AliESDtrack *)fTracks.UncheckedAt(i); |
55 | } | |
482070f2 | 56 | AliESDHLTtrack *GetHLTConfMapTrack(Int_t i) const { |
57 | return (AliESDHLTtrack *)fHLTConfMapTracks.UncheckedAt(i); | |
58 | } | |
59 | AliESDHLTtrack *GetHLTHoughTrack(Int_t i) const { | |
60 | return (AliESDHLTtrack *)fHLTHoughTracks.UncheckedAt(i); | |
61 | } | |
873f1f73 | 62 | AliESDMuonTrack *GetMuonTrack(Int_t i) const { |
672b5f43 | 63 | return (AliESDMuonTrack *)fMuonTracks.UncheckedAt(i); |
64 | } | |
561b7b31 | 65 | AliESDPmdTrack *GetPmdTrack(Int_t i) const { |
66 | return (AliESDPmdTrack *)fPmdTracks.UncheckedAt(i); | |
67 | } | |
0ee00e25 | 68 | AliESDTrdTrack *GetTrdTrack(Int_t i) const { |
69 | return (AliESDTrdTrack *)fTrdTracks.UncheckedAt(i); | |
70 | } | |
672b5f43 | 71 | |
51ad6848 | 72 | Int_t AddTrack(const AliESDtrack *t) { |
73 | AliESDtrack * track = new(fTracks[fTracks.GetEntriesFast()]) AliESDtrack(*t); | |
74 | track->SetID(fTracks.GetEntriesFast()-1); | |
75 | return track->GetID(); | |
76 | ||
ae982df3 | 77 | } |
482070f2 | 78 | void AddHLTConfMapTrack(const AliESDHLTtrack *t) { |
79 | new(fHLTConfMapTracks[fHLTConfMapTracks.GetEntriesFast()]) AliESDHLTtrack(*t); | |
80 | } | |
81 | void AddHLTHoughTrack(const AliESDHLTtrack *t) { | |
82 | new(fHLTHoughTracks[fHLTHoughTracks.GetEntriesFast()]) AliESDHLTtrack(*t); | |
83 | } | |
672b5f43 | 84 | void AddMuonTrack(const AliESDMuonTrack *t) { |
85 | new(fMuonTracks[fMuonTracks.GetEntriesFast()]) AliESDMuonTrack(*t); | |
86 | } | |
561b7b31 | 87 | void AddPmdTrack(const AliESDPmdTrack *t) { |
88 | new(fPmdTracks[fPmdTracks.GetEntriesFast()]) AliESDPmdTrack(*t); | |
89 | } | |
0ee00e25 | 90 | void AddTrdTrack(const AliESDTrdTrack *t) { |
91 | new(fTrdTracks[fTrdTracks.GetEntriesFast()]) AliESDTrdTrack(*t); | |
92 | } | |
8a8d023f | 93 | |
873f1f73 | 94 | AliESDv0 *GetV0(Int_t i) const { |
e23730c7 | 95 | return (AliESDv0 *)fV0s.UncheckedAt(i); |
96 | } | |
d6a49f20 | 97 | Int_t AddV0(const AliESDv0 *v); |
e23730c7 | 98 | |
873f1f73 | 99 | AliESDcascade *GetCascade(Int_t i) const { |
e23730c7 | 100 | return (AliESDcascade *)fCascades.UncheckedAt(i); |
101 | } | |
102 | void AddCascade(const AliESDcascade *c) { | |
103 | new(fCascades[fCascades.GetEntriesFast()]) AliESDcascade(*c); | |
104 | } | |
105 | ||
51ad6848 | 106 | AliESDkink *GetKink(Int_t i) const { |
107 | return (AliESDkink *)fKinks.UncheckedAt(i); | |
108 | } | |
109 | Int_t AddKink(const AliESDkink *c) { | |
110 | AliESDkink * kink = new(fKinks[fKinks.GetEntriesFast()]) AliESDkink(*c); | |
111 | kink->SetID(fKinks.GetEntriesFast()); | |
112 | return fKinks.GetEntriesFast()-1; | |
113 | } | |
114 | ||
85c60a8e | 115 | AliESDCaloCluster *GetCaloCluster(Int_t i) const { |
116 | return (AliESDCaloCluster *)fCaloClusters.UncheckedAt(i); | |
117 | } | |
118 | Int_t AddCaloCluster(const AliESDCaloCluster *c) { | |
119 | AliESDCaloCluster *clus = new(fCaloClusters[fCaloClusters.GetEntriesFast()]) AliESDCaloCluster(*c); | |
120 | clus->SetID(fCaloClusters.GetEntriesFast()-1); | |
121 | return fCaloClusters.GetEntriesFast()-1; | |
122 | } | |
123 | ||
15b965a7 | 124 | void SetVertex(const AliESDVertex *vertex) { |
125 | new (&fSPDVertex) AliESDVertex(*vertex); | |
2257f27e | 126 | } |
15b965a7 | 127 | const AliESDVertex *GetVertex() const {return &fSPDVertex;} |
c5e3e5d1 | 128 | |
32e449be | 129 | void SetMultiplicity(const AliMultiplicity *mul) { |
130 | new (&fSPDMult) AliMultiplicity(*mul); | |
131 | } | |
132 | const AliMultiplicity *GetMultiplicity() const {return &fSPDMult;} | |
133 | ||
15b965a7 | 134 | void SetPrimaryVertex(const AliESDVertex *vertex) { |
135 | new (&fPrimaryVertex) AliESDVertex(*vertex); | |
c5e3e5d1 | 136 | } |
15b965a7 | 137 | const AliESDVertex *GetPrimaryVertex() const {return &fPrimaryVertex;} |
873f1f73 | 138 | |
ae982df3 | 139 | Int_t GetEventNumber() const {return fEventNumber;} |
140 | Int_t GetRunNumber() const {return fRunNumber;} | |
001397cd | 141 | UInt_t GetTimeStamp() const { return fTimeStamp;} |
142 | UInt_t GetEventType() const { return fEventType;} | |
b647652d | 143 | ULong64_t GetTriggerMask() const {return fTriggerMask;} |
144 | UChar_t GetTriggerCluster() const {return fTriggerCluster;} | |
8a8d023f | 145 | |
672b5f43 | 146 | Int_t GetNumberOfTracks() const {return fTracks.GetEntriesFast();} |
482070f2 | 147 | Int_t GetNumberOfHLTConfMapTracks() const {return fHLTConfMapTracks.GetEntriesFast();} |
148 | Int_t GetNumberOfHLTHoughTracks() const {return fHLTHoughTracks.GetEntriesFast();} | |
672b5f43 | 149 | Int_t GetNumberOfMuonTracks() const {return fMuonTracks.GetEntriesFast();} |
561b7b31 | 150 | Int_t GetNumberOfPmdTracks() const {return fPmdTracks.GetEntriesFast();} |
0ee00e25 | 151 | Int_t GetNumberOfTrdTracks() const {return fTrdTracks.GetEntriesFast();} |
e23730c7 | 152 | Int_t GetNumberOfV0s() const {return fV0s.GetEntriesFast();} |
153 | Int_t GetNumberOfCascades() const {return fCascades.GetEntriesFast();} | |
51ad6848 | 154 | Int_t GetNumberOfKinks() const {return fKinks.GetEntriesFast();} |
85c60a8e | 155 | Int_t GetNumberOfCaloClusters() const {return fCaloClusters.GetEntriesFast();} |
156 | ||
157 | Int_t GetNumberOfEMCALClusters() const {return fEMCALClusters;} | |
158 | void SetNumberOfEMCALClusters(Int_t clus) {fEMCALClusters = clus;} | |
159 | Int_t GetFirstEMCALCluster() const {return fFirstEMCALCluster;} | |
160 | void SetFirstEMCALCluster(Int_t index) {fFirstEMCALCluster = index;} | |
161 | ||
162 | Int_t GetNumberOfPHOSClusters() const {return fPHOSClusters;} | |
163 | void SetNumberOfPHOSClusters(Int_t part) { fPHOSClusters = part ; } | |
164 | void SetFirstPHOSCluster(Int_t index) { fFirstPHOSCluster = index ; } | |
165 | Int_t GetFirstPHOSCluster() const { return fFirstPHOSCluster ; } | |
a2882fb4 | 166 | |
4a78b8c5 | 167 | Float_t GetT0zVertex() const {return fT0zVertex;} |
168 | void SetT0zVertex(Float_t z) {fT0zVertex=z;} | |
6d45eaef | 169 | Float_t GetT0() const {return fT0timeStart;} |
170 | void SetT0(Float_t timeStart) {fT0timeStart = timeStart;} | |
171 | const Float_t * GetT0time() const {return fT0time;} | |
172 | void SetT0time(Float_t time[24]) { | |
173 | for (Int_t i=0; i<24; i++) fT0time[i] = time[i]; | |
174 | } | |
175 | const Float_t * GetT0amplitude() const {return fT0amplitude;} | |
176 | void SetT0amplitude(Float_t amp[24]) { | |
177 | for (Int_t i=0; i<24; i++) fT0amplitude[i] = amp[i]; | |
178 | } | |
ef278eae | 179 | |
32a5cab4 | 180 | Float_t GetZDCN1Energy() const {return fZDCN1Energy;} |
181 | Float_t GetZDCP1Energy() const {return fZDCP1Energy;} | |
182 | Float_t GetZDCN2Energy() const {return fZDCN2Energy;} | |
183 | Float_t GetZDCP2Energy() const {return fZDCP2Energy;} | |
878bc0c2 | 184 | Float_t GetZDCEMEnergy() const {return fZDCEMEnergy;} |
185 | Int_t GetZDCParticipants() const {return fZDCParticipants;} | |
32a5cab4 | 186 | void SetZDC(Float_t n1Energy, Float_t p1Energy, Float_t emEnergy, |
187 | Float_t n2Energy, Float_t p2Energy, Int_t participants) | |
188 | {fZDCN1Energy=n1Energy; fZDCP1Energy=p1Energy; fZDCEMEnergy=emEnergy; | |
189 | fZDCN2Energy=n2Energy; fZDCP2Energy=p2Energy; fZDCParticipants=participants;} | |
878bc0c2 | 190 | |
50ca5f39 | 191 | void ResetV0s() { fV0s.Clear(); } |
192 | void ResetCascades() { fCascades.Clear(); } | |
193 | void Reset(); | |
bf25155c | 194 | |
ef278eae | 195 | void Print(Option_t *option="") const; |
9da38871 | 196 | |
dd735cf0 | 197 | void SetFMDData(AliESDFMD * obj) { fESDFMD = new AliESDFMD(*obj); } |
198 | AliESDFMD *GetFMDData(){ return fESDFMD; } | |
199 | ||
200 | void SetVZEROData(AliESDVZERO * obj) { fESDVZERO = new AliESDVZERO(*obj); } | |
201 | AliESDVZERO *GetVZEROData(){ return fESDVZERO; } | |
ef278eae | 202 | |
8a8d023f | 203 | protected: |
c028b974 | 204 | AliESD(const AliESD&); |
fe12e09c | 205 | AliESD &operator=(const AliESD& source); |
8a8d023f | 206 | |
207 | // Event Identification | |
ae982df3 | 208 | Int_t fEventNumber; // Event Number |
209 | Int_t fRunNumber; // Run Number | |
001397cd | 210 | UInt_t fTimeStamp; // Time stamp |
211 | UInt_t fEventType; // Type of Event | |
b647652d | 212 | ULong64_t fTriggerMask; // Trigger Type (mask) |
213 | UChar_t fTriggerCluster; // Trigger cluster (mask) | |
ae982df3 | 214 | Int_t fRecoVersion; // Version of reconstruction |
a866ac60 | 215 | Float_t fMagneticField; // Solenoid Magnetic Field in kG : for compatibility with AliMagF |
8a8d023f | 216 | |
32a5cab4 | 217 | Float_t fZDCN1Energy; // reconstructed energy in the neutron ZDC |
218 | Float_t fZDCP1Energy; // reconstructed energy in the proton ZDC | |
219 | Float_t fZDCN2Energy; // reconstructed energy in the neutron ZDC | |
220 | Float_t fZDCP2Energy; // reconstructed energy in the proton ZDC | |
878bc0c2 | 221 | Float_t fZDCEMEnergy; // reconstructed energy in the electromagnetic ZDC |
222 | Int_t fZDCParticipants; // number of participants estimated by the ZDC | |
223 | ||
ababa197 | 224 | Float_t fT0zVertex; // vertex z position estimated by the T0 |
15b965a7 | 225 | AliESDVertex fSPDVertex; // Primary vertex estimated by the SPD |
226 | AliESDVertex fPrimaryVertex; // Primary vertex estimated using ESD tracks | |
32e449be | 227 | AliMultiplicity fSPDMult; // SPD tracklet multiplicity |
c5e3e5d1 | 228 | |
ababa197 | 229 | Float_t fT0timeStart; // interaction time estimated by the T0 |
230 | Float_t fT0time[24]; // best TOF on each T0 PMT | |
231 | Float_t fT0amplitude[24]; // number of particles(MIPs) on each T0 PMT | |
8bbc564d | 232 | |
233 | TClonesArray fTracks; // ESD tracks | |
234 | TClonesArray fHLTConfMapTracks;// HLT ESD tracks from Conformal Mapper method | |
235 | TClonesArray fHLTHoughTracks; // HLT ESD tracks from Hough Transform method | |
236 | TClonesArray fMuonTracks; // MUON ESD tracks | |
237 | TClonesArray fPmdTracks; // PMD ESD tracks | |
0ee00e25 | 238 | TClonesArray fTrdTracks; // TRD ESD tracks (triggered) |
8bbc564d | 239 | TClonesArray fV0s; // V0 vertices |
240 | TClonesArray fCascades; // Cascade vertices | |
51ad6848 | 241 | TClonesArray fKinks; // Kinks |
85c60a8e | 242 | TClonesArray fCaloClusters; // Calorimeter clusters for PHOS/EMCAL |
243 | Int_t fEMCALClusters; // Number of EMCAL clusters (subset of caloclusters) | |
244 | Int_t fFirstEMCALCluster; // First EMCAL cluster in the fCaloClusters list | |
245 | ||
246 | Int_t fPHOSClusters; // Number of PHOS clusters (subset of caloclusters) | |
247 | Int_t fFirstPHOSCluster; // First PHOS cluster in the fCaloClusters list | |
704be597 | 248 | |
dd735cf0 | 249 | AliESDFMD *fESDFMD; // FMD object containing rough multiplicity |
250 | AliESDVZERO *fESDVZERO; // VZERO object containing rough multiplicity | |
9da38871 | 251 | |
dd735cf0 | 252 | ClassDef(AliESD,16) //ESD class |
8a8d023f | 253 | }; |
8a8d023f | 254 | #endif |
255 |