]>
Commit | Line | Data |
---|---|---|
af885e0f | 1 | // -*- mode: C++ -*- |
2 | #ifndef ALIESDEVENT_H | |
3 | #define ALIESDEVENT_H | |
4 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
5 | * See cxx source for full Copyright notice */ | |
6 | ||
7 | ||
5e319bd5 | 8 | /* $Id: AliESDEvent.h 64008 2013-08-28 13:09:59Z hristov $ */ |
af885e0f | 9 | |
10 | //------------------------------------------------------------------------- | |
f56a9fa7 | 11 | // Class AliESDEvent |
6989bff3 | 12 | // This is the class to deal with during the physics analysis of data. |
f56a9fa7 | 13 | // It also ensures the backward compatibility with the old ESD format. |
af885e0f | 14 | // |
f56a9fa7 | 15 | // Origin: Christian Klein-Boesing, CERN, Christian.Klein-Boesing@cern.ch |
af885e0f | 16 | //------------------------------------------------------------------------- |
17 | ||
18 | #include <TClonesArray.h> | |
19 | #include <TObject.h> | |
20 | #include <TTree.h> | |
21 | #include <TArrayF.h> | |
115179c6 | 22 | #include <TObjArray.h> |
af885e0f | 23 | |
af885e0f | 24 | |
024c7734 | 25 | #include "AliVEvent.h" |
694aad0c | 26 | // some includes for delegated methods |
f0106218 | 27 | #include "AliESDCaloTrigger.h" |
af885e0f | 28 | #include "AliESDRun.h" |
29 | #include "AliESDHeader.h" | |
3f47e572 | 30 | #include "AliESDTZERO.h" |
f0106218 | 31 | #include "AliESDZDC.h" |
bd95bae7 | 32 | #include "AliESDACORDE.h" |
5e319bd5 | 33 | #include "AliESDAD.h" |
9a003bdc | 34 | #include "AliMultiplicity.h" |
af885e0f | 35 | |
024c7734 | 36 | // AliESDtrack has to be included so that the compiler |
37 | // knows its inheritance tree (= that it is a AliVParticle). | |
38 | #include "AliESDtrack.h" | |
5303c167 | 39 | // same for AliESDVertex (which is a AliVVertex) |
40 | #include "AliESDVertex.h" | |
c8fe2783 | 41 | // same for CaloCells and CaloClusters (which is a AliVCaloCells, AliVCluster) |
42 | #include "AliESDCaloCluster.h" | |
43 | #include "AliESDCaloCells.h" | |
44 | ||
ae2bccf1 | 45 | #include "AliESDVZERO.h" |
9aa7ebff | 46 | #include "AliESDTrdTrack.h" |
49436743 | 47 | #include "AliESDTOFCluster.h" |
48 | #include "AliESDTOFHit.h" | |
49 | #include "AliESDTOFMatch.h" | |
08f45a9c | 50 | #include "AliESDfriend.h" |
2d63d380 | 51 | #include "AliESDv0.h" |
52 | ||
5f12e575 | 53 | class AliESDkink; |
af885e0f | 54 | class AliESDHLTtrack; |
f0106218 | 55 | class AliESDVertex; |
56 | class AliESDPmdTrack; | |
57 | class AliESDFMD; | |
f0106218 | 58 | class AliRawDataErrorLog; |
59 | class AliESDRun; | |
6c8e0967 | 60 | class AliESDTrdTrigger; |
52cd0cc0 | 61 | class AliESDTrdTracklet; |
f0106218 | 62 | class AliESDMuonTrack; |
fe0324de | 63 | class AliESDMuonCluster; |
64 | class AliESDMuonPad; | |
d3eabe96 | 65 | class AliESDMuonGlobalTrack; // AU |
af885e0f | 66 | class AliESD; |
f0106218 | 67 | class AliESDcascade; |
fba4b2e2 | 68 | class AliCentrality; |
ce7adfe9 | 69 | class AliEventplane; |
cd1d4ee0 | 70 | class TRefArray; |
bd95bae7 | 71 | class AliESDACORDE; |
5e319bd5 | 72 | class AliESDAD; |
8b12d288 | 73 | class AliESDHLTDecision; |
8e1324ab | 74 | class AliESDCosmicTrack; |
af885e0f | 75 | |
80791508 | 76 | class TList; |
77 | class TString; | |
78 | ||
d3eabe96 | 79 | |
024c7734 | 80 | class AliESDEvent : public AliVEvent { |
af885e0f | 81 | public: |
82 | ||
83 | ||
6989bff3 | 84 | enum ESDListIndex {kESDRun, |
af885e0f | 85 | kHeader, |
86 | kESDZDC, | |
87 | kESDFMD, | |
88 | kESDVZERO, | |
89 | kESDTZERO, | |
06cc9d95 | 90 | kTPCVertex, |
af885e0f | 91 | kSPDVertex, |
92 | kPrimaryVertex, | |
93 | kSPDMult, | |
94 | kPHOSTrigger, | |
95 | kEMCALTrigger, | |
04d01397 | 96 | kSPDPileupVertices, |
97 | kTrkPileupVertices, | |
af885e0f | 98 | kTracks, |
99 | kMuonTracks, | |
fe0324de | 100 | kMuonClusters, |
101 | kMuonPads, | |
d3eabe96 | 102 | kMuonGlobalTracks, // AU |
af885e0f | 103 | kPmdTracks, |
6c8e0967 | 104 | kTrdTrigger, |
af885e0f | 105 | kTrdTracks, |
52cd0cc0 | 106 | kTrdTracklets, |
af885e0f | 107 | kV0s, |
108 | kCascades, | |
109 | kKinks, | |
110 | kCaloClusters, | |
e649177a | 111 | kEMCALCells, |
112 | kPHOSCells, | |
af885e0f | 113 | kErrorLogs, |
bd95bae7 | 114 | kESDACORDE, |
5e319bd5 | 115 | kESDAD, |
f858b00e | 116 | kTOFHeader, |
8e1324ab | 117 | kCosmicTracks, |
49436743 | 118 | kTOFclusters, |
119 | kTOFhit, | |
120 | kTOFmatch, | |
af885e0f | 121 | kESDListN |
122 | }; | |
123 | ||
124 | AliESDEvent(); | |
732a24fe | 125 | virtual ~AliESDEvent(); |
126 | AliESDEvent &operator=(const AliESDEvent& source); // or make private and use only copy? | |
127 | virtual void Copy(TObject& obj) const; | |
af885e0f | 128 | |
129 | // RUN | |
130 | // move this to the UserData!!! | |
131 | const AliESDRun* GetESDRun() const {return fESDRun;} | |
132 | ||
133 | // Delegated methods for fESDRun | |
c017f53f | 134 | void SetRunNumber(Int_t n) {if(fESDRun) fESDRun->SetRunNumber(n);} |
135 | Int_t GetRunNumber() const {return fESDRun?fESDRun->GetRunNumber():-1;} | |
00d00f58 | 136 | void SetPeriodNumber(UInt_t n){ |
137 | if(fESDRun) fESDRun->SetPeriodNumber(n); | |
138 | if(fHeader) fHeader->SetPeriodNumber(n); | |
139 | } | |
c017f53f | 140 | UInt_t GetPeriodNumber() const {return fESDRun?fESDRun->GetPeriodNumber():0;} |
141 | void SetMagneticField(Double_t mf){if(fESDRun) fESDRun->SetMagneticField(mf);} | |
142 | Double_t GetMagneticField() const {return fESDRun?fESDRun->GetMagneticField():0;} | |
143 | void SetDiamond(const AliESDVertex *vertex) { if(fESDRun) fESDRun->SetDiamond(vertex);} | |
144 | Double_t GetDiamondX() const {return fESDRun?fESDRun->GetDiamondX():0;} | |
145 | Double_t GetDiamondY() const {return fESDRun?fESDRun->GetDiamondY():0;} | |
1c7554f9 | 146 | Double_t GetDiamondZ() const {return fESDRun?fESDRun->GetDiamondZ():0;} |
c017f53f | 147 | Double_t GetSigma2DiamondX() const {return fESDRun?fESDRun->GetSigma2DiamondX():0;} |
148 | Double_t GetSigma2DiamondY() const {return fESDRun?fESDRun->GetSigma2DiamondY():0;} | |
1c7554f9 | 149 | Double_t GetSigma2DiamondZ() const {return fESDRun?fESDRun->GetSigma2DiamondZ():0;} |
c017f53f | 150 | void GetDiamondCovXY(Float_t cov[3]) const {if(fESDRun) fESDRun->GetDiamondCovXY(cov);} |
151 | void SetTriggerClass(const char*name, Int_t index) {if(fESDRun) fESDRun->SetTriggerClass(name,index);} | |
152 | void SetPHOSMatrix(TGeoHMatrix*matrix, Int_t i) {if(fESDRun) fESDRun->SetPHOSMatrix(matrix,i);} | |
153 | const TGeoHMatrix* GetPHOSMatrix(Int_t i) const {return fESDRun?fESDRun->GetPHOSMatrix(i):0x0;} | |
154 | void SetEMCALMatrix(TGeoHMatrix*matrix, Int_t i) {if(fESDRun) fESDRun->SetEMCALMatrix(matrix,i);} | |
155 | const TGeoHMatrix* GetEMCALMatrix(Int_t i) const {return fESDRun?fESDRun->GetEMCALMatrix(i):0x0;} | |
da6062af | 156 | void SetCaloTriggerType(const Int_t* type) {if (fESDRun) fESDRun->SetCaloTriggerType(type);} |
1dc767cf | 157 | Int_t* GetCaloTriggerType() const {return fESDRun?fESDRun->GetCaloTriggerType():0x0;} |
5e14e698 | 158 | virtual const Float_t* GetVZEROEqFactors() const {return fESDRun?fESDRun->GetVZEROEqFactors():0x0;} |
159 | virtual Float_t GetVZEROEqMultiplicity(Int_t i) const; | |
da6062af | 160 | |
33fe5eb1 | 161 | // |
c017f53f | 162 | void SetCurrentL3(Float_t cur) const {if(fESDRun) fESDRun->SetCurrentL3(cur);} |
163 | void SetCurrentDip(Float_t cur) const {if(fESDRun) fESDRun->SetCurrentDip(cur);} | |
164 | void SetBeamEnergy(Float_t be) const {if(fESDRun) fESDRun->SetBeamEnergy(be);} | |
165 | void SetBeamType(const char* bt) const {if(fESDRun) fESDRun->SetBeamType(bt);} | |
91460b26 | 166 | void SetBeamParticle(Int_t az, Int_t ibeam) {if(fESDRun) fESDRun->SetBeamParticle(az,ibeam);} |
c017f53f | 167 | void SetUniformBMap(Bool_t val=kTRUE) const {if(fESDRun) fESDRun->SetBit(AliESDRun::kUniformBMap,val);} |
168 | void SetBInfoStored(Bool_t val=kTRUE) const {if(fESDRun) fESDRun->SetBit(AliESDRun::kBInfoStored,val);} | |
33fe5eb1 | 169 | // |
c017f53f | 170 | Float_t GetCurrentL3() const {return fESDRun?fESDRun->GetCurrentL3():0;} |
171 | Float_t GetCurrentDip() const {return fESDRun?fESDRun->GetCurrentDip():0;} | |
172 | Float_t GetBeamEnergy() const {return fESDRun?fESDRun->GetBeamEnergy():0;} | |
173 | const char* GetBeamType() const {return fESDRun?fESDRun->GetBeamType():0;} | |
91460b26 | 174 | Int_t GetBeamParticle(Int_t ibeam) const {return fESDRun?fESDRun->GetBeamParticle(ibeam):0;} |
175 | Int_t GetBeamParticleA(Int_t ibeam) const {return fESDRun?fESDRun->GetBeamParticleA(ibeam):0;} | |
176 | Int_t GetBeamParticleZ(Int_t ibeam) const {return fESDRun?fESDRun->GetBeamParticleZ(ibeam):0;} | |
c017f53f | 177 | Bool_t IsUniformBMap() const {return fESDRun?fESDRun->TestBit(AliESDRun::kUniformBMap):kFALSE;} |
33fe5eb1 | 178 | // |
127be208 | 179 | virtual Bool_t InitMagneticField() const {return fESDRun?fESDRun->InitMagneticField():kFALSE;} |
78cbd205 | 180 | void SetT0spread(Float_t *t) const {if(fESDRun) fESDRun->SetT0spread(t);} |
181 | Float_t GetT0spread(Int_t i) const {return fESDRun?fESDRun->GetT0spread(i):0;} | |
cc4d0e9c | 182 | virtual void SetVZEROEqFactors(Float_t factors[64]) const {if(fESDRun) fESDRun->SetVZEROEqFactors(factors);} |
af885e0f | 183 | // HEADER |
024c7734 | 184 | AliESDHeader* GetHeader() const {return fHeader;} |
af885e0f | 185 | |
186 | // Delegated methods for fHeader | |
c017f53f | 187 | void SetTriggerMask(ULong64_t n) {if(fHeader) fHeader->SetTriggerMask(n);} |
6848e3be | 188 | void SetTriggerMaskNext50(ULong64_t n) {if(fHeader) fHeader->SetTriggerMaskNext50(n);} |
c017f53f | 189 | void SetOrbitNumber(UInt_t n) {if(fHeader) fHeader->SetOrbitNumber(n);} |
190 | void SetTimeStamp(UInt_t timeStamp){if(fHeader) fHeader->SetTimeStamp(timeStamp);} | |
191 | void SetEventType(UInt_t eventType){if(fHeader) fHeader->SetEventType(eventType);} | |
192 | void SetEventSpecie(UInt_t eventSpecie){if(fHeader) fHeader->SetEventSpecie(eventSpecie);} | |
193 | void SetEventNumberInFile(Int_t n) {if(fHeader) fHeader->SetEventNumberInFile(n);} | |
194 | // void SetRunNumber(Int_t n) {if(fHeader) fHeader->SetRunNumber(n);} | |
195 | void SetBunchCrossNumber(UShort_t n) {if(fHeader) fHeader->SetBunchCrossNumber(n);} | |
196 | void SetTriggerCluster(UChar_t n) {if(fHeader) fHeader->SetTriggerCluster(n);} | |
694aad0c | 197 | |
c017f53f | 198 | ULong64_t GetTriggerMask() const {return fHeader?fHeader->GetTriggerMask():0;} |
6848e3be | 199 | ULong64_t GetTriggerMaskNext50() const {return fHeader?fHeader->GetTriggerMaskNext50():0;} |
200 | //TString GetFiredTriggerClasses() const {return (fESDRun&&fHeader)?fESDRun->GetFiredTriggerClasses(fHeader->GetTriggerMask()):"";} | |
201 | TString GetFiredTriggerClasses() const {return (fESDRun&&fHeader)?fESDRun->GetFiredTriggerClasses(fHeader->GetTriggerMask(),fHeader->GetTriggerMaskNext50()):"";} | |
202 | //Bool_t IsTriggerClassFired(const char *name) const {return (fESDRun&&fHeader)?fESDRun->IsTriggerClassFired(fHeader->GetTriggerMask(),name):kFALSE;} | |
203 | Bool_t IsTriggerClassFired(const char *name) const {return (fESDRun&&fHeader)?fESDRun->IsTriggerClassFired(fHeader->GetTriggerMask(),fHeader->GetTriggerMaskNext50(),name):kFALSE;} | |
2a3dfb14 | 204 | Bool_t IsEventSelected(const char *trigExpr) const; |
3b286f80 | 205 | TObject* GetHLTTriggerDecision() const; |
206 | TString GetHLTTriggerDescription() const; | |
207 | Bool_t IsHLTTriggerFired(const char* name=NULL) const; | |
158a76dd | 208 | UInt_t GetOrbitNumber() const {return fHeader?fHeader->GetOrbitNumber():0;} |
c017f53f | 209 | UInt_t GetTimeStamp() const { return fHeader?fHeader->GetTimeStamp():0;} |
210 | UInt_t GetEventType() const { return fHeader?fHeader->GetEventType():0;} | |
211 | UInt_t GetEventSpecie() const { return fHeader?fHeader->GetEventSpecie():0;} | |
212 | Int_t GetEventNumberInFile() const {return fHeader?fHeader->GetEventNumberInFile():-1;} | |
213 | UShort_t GetBunchCrossNumber() const {return fHeader?fHeader->GetBunchCrossNumber():0;} | |
214 | UChar_t GetTriggerCluster() const {return fHeader?fHeader->GetTriggerCluster():0;} | |
766037f0 | 215 | Bool_t IsDetectorInTriggerCluster(TString detector, AliTriggerConfiguration* trigConf) const; |
af885e0f | 216 | // ZDC CKB: put this in the header? |
16d867eb | 217 | AliESDZDC* GetESDZDC() const {return fESDZDC;} |
218 | AliESDZDC* GetZDCData() const {return fESDZDC;} | |
219 | ||
5d8eaff6 | 220 | void SetZDCData(const AliESDZDC * obj); |
af885e0f | 221 | |
222 | // Delegated methods for fESDZDC | |
c017f53f | 223 | Double_t GetZDCN1Energy() const {return fESDZDC?fESDZDC->GetZDCN1Energy():0;} |
224 | Double_t GetZDCP1Energy() const {return fESDZDC?fESDZDC->GetZDCP1Energy():0;} | |
225 | Double_t GetZDCN2Energy() const {return fESDZDC?fESDZDC->GetZDCN2Energy():0;} | |
226 | Double_t GetZDCP2Energy() const {return fESDZDC?fESDZDC->GetZDCP2Energy():0;} | |
227 | Double_t GetZDCEMEnergy(Int_t i=0) const {return fESDZDC?fESDZDC->GetZDCEMEnergy(i):0;} | |
228 | Int_t GetZDCParticipants() const {return fESDZDC?fESDZDC->GetZDCParticipants():0;} | |
fba4b2e2 | 229 | AliCentrality* GetCentrality(); |
ce7adfe9 | 230 | AliEventplane* GetEventplane(); |
cb62947d | 231 | |
2eec2a33 | 232 | |
b19cc8d0 | 233 | void SetZDC(Float_t n1Energy, Float_t p1Energy, Float_t em1Energy, Float_t em2Energy, |
234 | Float_t n2Energy, Float_t p2Energy, Int_t participants, Int_t nPartA, | |
235 | Int_t nPartC, Double_t b, Double_t bA, Double_t bC, UInt_t recoflag) | |
c017f53f | 236 | {if(fESDZDC) fESDZDC->SetZDC(n1Energy, p1Energy, em1Energy, em2Energy, n2Energy, p2Energy, |
b19cc8d0 | 237 | participants, nPartA, nPartC, b, bA, bC, recoflag);} |
cb62947d | 238 | // FMD |
af885e0f | 239 | void SetFMDData(AliESDFMD * obj); |
5b96d6f1 | 240 | AliESDFMD *GetFMDData() const { return fESDFMD; } |
af885e0f | 241 | |
242 | ||
243 | // TZERO CKB: put this in the header? | |
244 | const AliESDTZERO* GetESDTZERO() const {return fESDTZERO;} | |
5d8eaff6 | 245 | void SetTZEROData(const AliESDTZERO * obj); |
b0e13b29 | 246 | // delegetated methods for fESDTZERO |
af885e0f | 247 | |
adf36b9d | 248 | Double32_t GetT0zVertex() const {return fESDTZERO?fESDTZERO->GetT0zVertex():0;} |
249 | void SetT0zVertex(Double32_t z) {if(fESDTZERO) fESDTZERO->SetT0zVertex(z);} | |
250 | Double32_t GetT0() const {return fESDTZERO?fESDTZERO->GetT0():0;} | |
251 | void SetT0(Double32_t timeStart) {if(fESDTZERO) fESDTZERO->SetT0(timeStart);} | |
252 | Double32_t GetT0clock() const {return fESDTZERO?fESDTZERO->GetT0clock():0;} | |
253 | void SetT0clock(Double32_t timeStart) {if(fESDTZERO) fESDTZERO->SetT0clock(timeStart);} | |
254 | Double32_t GetT0TOF(Int_t icase) const {return fESDTZERO?fESDTZERO->GetT0TOF(icase):0;} | |
255 | const Double32_t * GetT0TOF() const {return fESDTZERO?fESDTZERO->GetT0TOF():0x0;} | |
256 | void SetT0TOF(Int_t icase,Double32_t timeStart) {if(fESDTZERO) fESDTZERO->SetT0TOF(icase,timeStart);} | |
257 | const Double32_t * GetT0time() const {return fESDTZERO?fESDTZERO->GetT0time():0x0;} | |
258 | void SetT0time(Double32_t time[24]) {if(fESDTZERO) fESDTZERO->SetT0time(time);} | |
259 | const Double32_t * GetT0amplitude() const {return fESDTZERO?fESDTZERO->GetT0amplitude():0x0;} | |
260 | void SetT0amplitude(Double32_t amp[24]){if(fESDTZERO) fESDTZERO->SetT0amplitude(amp);} | |
261 | Int_t GetT0Trig() const { return fESDTZERO?fESDTZERO->GetT0Trig():0;} | |
262 | void SetT0Trig(Int_t tvdc) {if(fESDTZERO) fESDTZERO->SetT0Trig(tvdc);} | |
af885e0f | 263 | |
264 | // VZERO | |
265 | AliESDVZERO *GetVZEROData() const { return fESDVZERO; } | |
5d8eaff6 | 266 | void SetVZEROData(const AliESDVZERO * obj); |
820b4d9e | 267 | |
bd95bae7 | 268 | // ACORDE |
269 | AliESDACORDE *GetACORDEData() const { return fESDACORDE;} | |
270 | void SetACORDEData(AliESDACORDE * obj); | |
af885e0f | 271 | |
5e319bd5 | 272 | // AD |
273 | AliESDAD *GetADData() const { return fESDAD;} | |
274 | void SetADData(AliESDAD * obj); | |
275 | ||
276 | ||
277 | ||
278 | ||
7d44c466 | 279 | void SetESDfriend(const AliESDfriend *f) const; |
af885e0f | 280 | void GetESDfriend(AliESDfriend *f) const; |
21e601a3 | 281 | virtual AliESDfriend* FindFriend() const; |
af885e0f | 282 | |
06cc9d95 | 283 | void SetPrimaryVertexTPC(const AliESDVertex *vertex); |
284 | const AliESDVertex *GetPrimaryVertexTPC() const {return fTPCVertex;} | |
285 | ||
286 | void SetPrimaryVertexSPD(const AliESDVertex *vertex); | |
287 | const AliESDVertex *GetPrimaryVertexSPD() const {return fSPDVertex;} | |
288 | const AliESDVertex *GetVertex() const { | |
289 | //For the backward compatibily only | |
290 | return GetPrimaryVertexSPD(); | |
291 | } | |
af885e0f | 292 | |
c264b61b | 293 | void SetPrimaryVertexTracks(const AliESDVertex *vertex); |
294 | const AliESDVertex *GetPrimaryVertexTracks() const {return fPrimaryVertex;} | |
518573d7 | 295 | AliESDVertex *PrimaryVertexTracksUnconstrained() const; |
c264b61b | 296 | |
297 | const AliESDVertex *GetPrimaryVertex() const; | |
af885e0f | 298 | |
e3d1b1e2 | 299 | //getters for calibration |
300 | Int_t GetPrimaryVertex (AliESDVertex &v) const { | |
301 | if(!GetPrimaryVertex()) return -1; | |
302 | v=*GetPrimaryVertex(); | |
303 | return 0; | |
304 | } | |
305 | ||
306 | Int_t GetPrimaryVertexTPC (AliESDVertex &v) const { | |
307 | if(!GetPrimaryVertexTPC()) return -1; | |
308 | v=*GetPrimaryVertexTPC(); | |
309 | return 0; | |
310 | } | |
311 | ||
312 | Int_t GetPrimaryVertexSPD (AliESDVertex &v) const { | |
313 | if(!GetPrimaryVertexSPD()) return -1; | |
314 | v=*GetPrimaryVertexSPD(); | |
315 | return 0; | |
316 | } | |
317 | ||
318 | Int_t GetPrimaryVertexTracks (AliESDVertex &v) const { | |
319 | if(!GetPrimaryVertexTracks()) return -1; | |
320 | v=*GetPrimaryVertexTracks(); | |
321 | return 0; | |
322 | } | |
f858b00e | 323 | |
324 | ||
325 | void SetTOFHeader(const AliTOFHeader * tofEventTime); | |
49a1368d | 326 | AliTOFHeader *GetTOFHeader() const {return fTOFHeader;} |
d9fc7e74 | 327 | Float_t GetEventTimeSpread() const {if (fTOFHeader) return fTOFHeader->GetT0spread(); else return 0.;} |
328 | Float_t GetTOFTimeResolution() const {if (fTOFHeader) return fTOFHeader->GetTOFResolution(); else return 0.;} | |
49436743 | 329 | |
330 | TClonesArray *GetESDTOFClusters() const {return fESDTOFClusters;} | |
331 | TClonesArray *GetESDTOFHits() const {return fESDTOFHits;} | |
e073156e | 332 | TClonesArray *GetESDTOFMatches() const {return fESDTOFMatches;} |
49436743 | 333 | |
334 | void SetTOFcluster(Int_t ntofclusters,AliESDTOFCluster *cluster,Int_t *mapping=NULL); | |
335 | void SetTOFcluster(Int_t ntofclusters,AliESDTOFCluster *cluster[],Int_t *mapping=NULL); | |
336 | Int_t GetNTOFclusters() const {return fESDTOFClusters ? fESDTOFClusters->GetEntriesFast() : 0;} | |
f858b00e | 337 | |
fa1c0df5 | 338 | Int_t GetNumberOfITSClusters(Int_t lr) const {return fSPDMult ? fSPDMult->GetNumberOfITSClusters(lr) : 0;} |
f0106218 | 339 | void SetMultiplicity(const AliMultiplicity *mul); |
340 | ||
9a003bdc | 341 | AliMultiplicity *GetMultiplicity() const {return fSPDMult;} |
4ace6760 | 342 | void EstimateMultiplicity(Int_t &tracklets,Int_t &trITSTPC,Int_t &trITSSApure, |
343 | Double_t eta=1.,Bool_t useDCAFlag=kTRUE,Bool_t useV0Flag=kTRUE) const; | |
f0106218 | 344 | |
7f68891d | 345 | Bool_t Clean(Float_t *cleanPars); |
7d44c466 | 346 | Bool_t RemoveKink(Int_t i) const; |
347 | Bool_t RemoveV0(Int_t i) const; | |
348 | Bool_t RemoveTrack(Int_t i) const; | |
d64bd07d | 349 | |
04d01397 | 350 | const AliESDVertex *GetPileupVertexSPD(Int_t i) const { |
c8975fcf | 351 | return (const AliESDVertex *)(fSPDPileupVertices?fSPDPileupVertices->At(i):0x0); |
04d01397 | 352 | } |
6dc21f57 | 353 | Char_t AddPileupVertexSPD(const AliESDVertex *vtx); |
04d01397 | 354 | const AliESDVertex *GetPileupVertexTracks(Int_t i) const { |
c8975fcf | 355 | return (const AliESDVertex *)(fTrkPileupVertices?fTrkPileupVertices->At(i):0x0); |
04d01397 | 356 | } |
6dc21f57 | 357 | Char_t AddPileupVertexTracks(const AliESDVertex *vtx); |
3f2db92f | 358 | TClonesArray* GetPileupVerticesTracks() const {return (TClonesArray*)fTrkPileupVertices;} |
359 | TClonesArray* GetPileupVerticesSPD() const {return (TClonesArray*)fSPDPileupVertices;} | |
04d01397 | 360 | |
a98c78e5 | 361 | virtual Bool_t IsPileupFromSPD(Int_t minContributors=3, |
362 | Double_t minZdist=0.8, | |
363 | Double_t nSigmaZdist=3., | |
364 | Double_t nSigmaDiamXY=2., | |
365 | Double_t nSigmaDiamZ=5.) const; | |
366 | ||
b46ff4b0 | 367 | virtual Bool_t IsPileupFromSPDInMultBins() const; |
368 | ||
d38034b8 | 369 | void ConnectTracks(); |
370 | Bool_t AreTracksConnected() const {return fTracksConnected;} | |
371 | ||
372 | AliESDtrack *GetTrack(Int_t i) const {return (fTracks)?(AliESDtrack*)fTracks->At(i) : 0;} | |
af885e0f | 373 | Int_t AddTrack(const AliESDtrack *t); |
374 | ||
eb83d9ed | 375 | AliESDtrack *GetVTrack(Int_t i) const {return GetTrack(i);} |
376 | ||
65a0cf79 | 377 | /// add new track at the end of tracks array and return instance |
378 | AliESDtrack* NewTrack(); | |
af885e0f | 379 | |
380 | AliESDHLTtrack *GetHLTConfMapTrack(Int_t /*i*/) const { | |
c8975fcf | 381 | // return (AliESDHLTtrack *)fHLTConfMapTracks->At(i); |
af885e0f | 382 | return 0; |
383 | } | |
384 | void AddHLTConfMapTrack(const AliESDHLTtrack */*t*/) { | |
385 | printf("ESD:: AddHLTConfMapTrack do nothing \n"); | |
386 | // TClonesArray &fhlt = *fHLTConfMapTracks; | |
387 | // new(fhlt[fHLTConfMapTracks->GetEntriesFast()]) AliESDHLTtrack(*t); | |
388 | } | |
389 | ||
390 | ||
391 | AliESDHLTtrack *GetHLTHoughTrack(Int_t /*i*/) const { | |
c8975fcf | 392 | // return (AliESDHLTtrack *)fHLTHoughTracks->At(i); |
af885e0f | 393 | return 0; |
394 | } | |
395 | void AddHLTHoughTrack(const AliESDHLTtrack */*t*/) { | |
396 | printf("ESD:: AddHLTHoughTrack do nothing \n"); | |
397 | // TClonesArray &fhlt = *fHLTHoughTracks; | |
398 | // new(fhlt[fHLTHoughTracks->GetEntriesFast()]) AliESDHLTtrack(*t); | |
399 | } | |
400 | ||
fe0324de | 401 | Bool_t MoveMuonObjects(); |
402 | ||
403 | AliESDMuonTrack* GetMuonTrack(Int_t i); | |
404 | AliESDMuonTrack* NewMuonTrack(); | |
405 | ||
406 | AliESDMuonCluster* GetMuonCluster(Int_t i); | |
407 | AliESDMuonCluster* FindMuonCluster(UInt_t clusterId); | |
408 | AliESDMuonCluster* NewMuonCluster(); | |
409 | ||
410 | AliESDMuonPad* GetMuonPad(Int_t i); | |
411 | AliESDMuonPad* FindMuonPad(UInt_t padId); | |
412 | AliESDMuonPad* NewMuonPad(); | |
413 | ||
d3eabe96 | 414 | AliESDMuonGlobalTrack* GetMuonGlobalTrack(Int_t i); // AU |
415 | AliESDMuonGlobalTrack* NewMuonGlobalTrack(); // AU | |
416 | ||
af885e0f | 417 | AliESDPmdTrack *GetPmdTrack(Int_t i) const { |
c8975fcf | 418 | return (AliESDPmdTrack *)(fPmdTracks?fPmdTracks->At(i):0x0); |
af885e0f | 419 | } |
f0106218 | 420 | |
421 | void AddPmdTrack(const AliESDPmdTrack *t); | |
422 | ||
af885e0f | 423 | |
424 | AliESDTrdTrack *GetTrdTrack(Int_t i) const { | |
c8975fcf | 425 | return (AliESDTrdTrack *)(fTrdTracks?fTrdTracks->At(i):0x0); |
af885e0f | 426 | } |
f0106218 | 427 | |
428 | ||
6c8e0967 | 429 | void SetTrdTrigger(const AliESDTrdTrigger *t); |
430 | ||
431 | AliESDTrdTrigger* GetTrdTrigger() const { | |
432 | return (AliESDTrdTrigger*)(fTrdTrigger); | |
433 | } | |
434 | ||
f0106218 | 435 | void AddTrdTrack(const AliESDTrdTrack *t); |
af885e0f | 436 | |
52cd0cc0 | 437 | AliESDTrdTracklet* GetTrdTracklet(Int_t idx) const { |
c8975fcf | 438 | return (AliESDTrdTracklet*)(fTrdTracklets?fTrdTracklets->At(idx):0x0); |
52cd0cc0 | 439 | } |
440 | ||
441 | void AddTrdTracklet(const AliESDTrdTracklet *trkl); | |
60557224 | 442 | void AddTrdTracklet(UInt_t trackletWord, Short_t hcid, Int_t label = -1); |
52cd0cc0 | 443 | |
ea12701f | 444 | using AliVEvent::GetV0; |
af885e0f | 445 | AliESDv0 *GetV0(Int_t i) const { |
c8975fcf | 446 | return (AliESDv0*)(fV0s?fV0s->At(i):0x0); |
af885e0f | 447 | } |
2d63d380 | 448 | |
449 | Int_t GetV0(AliESDv0 &v0dum, Int_t i) const { | |
450 | if(!GetV0(i)) return -1; | |
451 | v0dum=*GetV0(i); | |
452 | return 0;} | |
453 | ||
af885e0f | 454 | Int_t AddV0(const AliESDv0 *v); |
455 | ||
456 | AliESDcascade *GetCascade(Int_t i) const { | |
c8975fcf | 457 | return (AliESDcascade *)(fCascades?fCascades->At(i):0x0); |
af885e0f | 458 | } |
f0106218 | 459 | |
460 | void AddCascade(const AliESDcascade *c); | |
af885e0f | 461 | |
462 | AliESDkink *GetKink(Int_t i) const { | |
c8975fcf | 463 | return (AliESDkink *)(fKinks?fKinks->At(i):0x0); |
af885e0f | 464 | } |
465 | Int_t AddKink(const AliESDkink *c); | |
466 | ||
467 | AliESDCaloCluster *GetCaloCluster(Int_t i) const { | |
c8975fcf | 468 | return (AliESDCaloCluster *)(fCaloClusters?fCaloClusters->At(i):0x0); |
af885e0f | 469 | } |
e649177a | 470 | |
af885e0f | 471 | Int_t AddCaloCluster(const AliESDCaloCluster *c); |
472 | ||
e649177a | 473 | AliESDCaloCells *GetEMCALCells() const {return fEMCALCells; } |
474 | AliESDCaloCells *GetPHOSCells() const {return fPHOSCells; } | |
475 | ||
042d5330 | 476 | AliESDCaloTrigger* GetCaloTrigger(TString calo) const |
477 | { | |
478 | if (calo.Contains("EMCAL")) return fEMCALTrigger; | |
479 | else | |
480 | return fPHOSTrigger; | |
481 | } | |
8e1324ab | 482 | |
483 | AliESDCosmicTrack *GetCosmicTrack(Int_t i) const { | |
c8975fcf | 484 | return fCosmicTracks ? (AliESDCosmicTrack*) fCosmicTracks->At(i) : 0; |
8e1324ab | 485 | } |
486 | const TClonesArray * GetCosmicTracks() const{ return fCosmicTracks;} | |
487 | ||
488 | void AddCosmicTrack(const AliESDCosmicTrack *t); | |
042d5330 | 489 | |
af885e0f | 490 | AliRawDataErrorLog *GetErrorLog(Int_t i) const { |
c8975fcf | 491 | return (AliRawDataErrorLog *)(fErrorLogs?fErrorLogs->At(i):0x0); |
af885e0f | 492 | } |
7d44c466 | 493 | void AddRawDataErrorLog(const AliRawDataErrorLog *log) const; |
f0106218 | 494 | |
c017f53f | 495 | Int_t GetNumberOfErrorLogs() const {return fErrorLogs?fErrorLogs->GetEntriesFast():0;} |
af885e0f | 496 | |
04d01397 | 497 | Int_t GetNumberOfPileupVerticesSPD() const { |
642f673b | 498 | return (fSPDPileupVertices?fSPDPileupVertices->GetEntriesFast():0); |
04d01397 | 499 | } |
500 | Int_t GetNumberOfPileupVerticesTracks() const { | |
642f673b | 501 | return (fTrkPileupVertices?fTrkPileupVertices->GetEntriesFast():0); |
04d01397 | 502 | } |
c017f53f | 503 | Int_t GetNumberOfTracks() const {return fTracks?fTracks->GetEntriesFast():0;} |
ef7661fd | 504 | Int_t GetNumberOfESDTracks() const { return GetNumberOfTracks(); } |
af885e0f | 505 | Int_t GetNumberOfHLTConfMapTracks() const {return 0;} |
506 | // fHLTConfMapTracks->GetEntriesFast();} | |
507 | Int_t GetNumberOfHLTHoughTracks() const {return 0; } | |
508 | // fHLTHoughTracks->GetEntriesFast(); } | |
509 | ||
c017f53f | 510 | Int_t GetNumberOfMuonTracks() const {return fMuonTracks?fMuonTracks->GetEntriesFast():0;} |
fe0324de | 511 | Int_t GetNumberOfMuonClusters(); |
512 | Int_t GetNumberOfMuonPads(); | |
d3eabe96 | 513 | Int_t GetNumberOfMuonGlobalTracks() const {return fMuonGlobalTracks?fMuonGlobalTracks->GetEntriesFast():0;} // AU |
c017f53f | 514 | Int_t GetNumberOfPmdTracks() const {return fPmdTracks?fPmdTracks->GetEntriesFast():0;} |
515 | Int_t GetNumberOfTrdTracks() const {return fTrdTracks?fTrdTracks->GetEntriesFast():0;} | |
52cd0cc0 | 516 | Int_t GetNumberOfTrdTracklets() const {return fTrdTracklets?fTrdTracklets->GetEntriesFast():0;} |
c017f53f | 517 | Int_t GetNumberOfV0s() const {return fV0s?fV0s->GetEntriesFast():0;} |
518 | Int_t GetNumberOfCascades() const {return fCascades?fCascades->GetEntriesFast():0;} | |
519 | Int_t GetNumberOfKinks() const {return fKinks?fKinks->GetEntriesFast():0;} | |
8e1324ab | 520 | |
521 | Int_t GetNumberOfCosmicTracks() const {return fCosmicTracks ? fCosmicTracks->GetEntriesFast():0;} | |
cd1d4ee0 | 522 | Int_t GetEMCALClusters(TRefArray *clusters) const; |
523 | Int_t GetPHOSClusters(TRefArray *clusters) const; | |
c017f53f | 524 | Int_t GetNumberOfCaloClusters() const {return fCaloClusters?fCaloClusters->GetEntriesFast():0;} |
af885e0f | 525 | |
a2fbb067 | 526 | void SetUseOwnList(Bool_t b){fUseOwnList = b;} |
b19cc8d0 | 527 | Bool_t GetUseOwnList() const {return fUseOwnList;} |
e649177a | 528 | |
c017f53f | 529 | void ResetV0s() { if(fV0s) fV0s->Clear(); } |
530 | void ResetCascades() { if(fCascades) fCascades->Clear(); } | |
af885e0f | 531 | void Reset(); |
532 | ||
533 | void Print(Option_t *option="") const; | |
534 | ||
535 | void AddObject(TObject* obj); | |
1d0dd492 | 536 | void ReadFromTree(TTree *tree, Option_t* opt = ""); |
2811495d | 537 | TObject* FindListObject(const char *name) const; |
af885e0f | 538 | AliESD *GetAliESDOld(){return fESDOld;} |
f12d42ce | 539 | void WriteToTree(TTree* tree) const; |
af885e0f | 540 | void GetStdContent(); |
541 | void ResetStdContent(); | |
542 | void CreateStdContent(); | |
a2fbb067 | 543 | void CreateStdContent(Bool_t bUseThisList); |
fe0324de | 544 | void CompleteStdContent(); |
af885e0f | 545 | void SetStdNames(); |
546 | void CopyFromOldESD(); | |
024c7734 | 547 | TList* GetList() const {return fESDObjects;} |
c8fe2783 | 548 | |
549 | //Following needed only for mixed event | |
550 | virtual Int_t EventIndex(Int_t) const {return 0;} | |
551 | virtual Int_t EventIndexForCaloCluster(Int_t) const {return 0;} | |
552 | virtual Int_t EventIndexForPHOSCell(Int_t) const {return 0;} | |
553 | virtual Int_t EventIndexForEMCALCell(Int_t) const {return 0;} | |
554 | ||
a8f382ab | 555 | void SetDetectorStatus(ULong_t detMask) {fDetectorStatus|=detMask;} |
556 | void ResetDetectorStatus(ULong_t detMask) {fDetectorStatus&=~detMask;} | |
557 | ULong_t GetDetectorStatus() const {return fDetectorStatus;} | |
558 | Bool_t IsDetectorOn(ULong_t detMask) const {return (fDetectorStatus&detMask)>0;} | |
af885e0f | 559 | |
8bc95619 | 560 | void SetDAQDetectorPattern(UInt_t pattern) {fDAQDetectorPattern = pattern;} |
561 | void SetDAQAttributes(UInt_t attributes) {fDAQAttributes = attributes;} | |
562 | UInt_t GetDAQDetectorPattern() const {return fDAQDetectorPattern;} | |
563 | UInt_t GetDAQAttributes() const {return fDAQAttributes;} | |
6a33e0e9 | 564 | |
15da855d | 565 | virtual AliVEvent::EDataLayoutType GetDataLayoutType() const; |
566 | ||
af885e0f | 567 | protected: |
568 | AliESDEvent(const AliESDEvent&); | |
102c56c8 | 569 | static Bool_t ResetWithPlacementNew(TObject *pObject); |
af885e0f | 570 | |
fe0324de | 571 | void AddMuonTrack(const AliESDMuonTrack *t); |
d3eabe96 | 572 | void AddMuonGlobalTrack(const AliESDMuonGlobalTrack *t); // AU |
fe0324de | 573 | |
af885e0f | 574 | TList *fESDObjects; // List of esd Objects |
575 | ||
576 | AliESDRun *fESDRun; //! Run information tmp put in the Userdata | |
577 | AliESDHeader *fHeader; //! ESD Event Header | |
578 | AliESDZDC *fESDZDC; //! ZDC information | |
579 | AliESDFMD *fESDFMD; //! FMD object containing rough multiplicity | |
580 | AliESDVZERO *fESDVZERO; //! VZERO object containing rough multiplicity | |
581 | AliESDTZERO *fESDTZERO; //! TZEROObject | |
06cc9d95 | 582 | AliESDVertex *fTPCVertex; //! Primary vertex estimated by the TPC |
af885e0f | 583 | AliESDVertex *fSPDVertex; //! Primary vertex estimated by the SPD |
584 | AliESDVertex *fPrimaryVertex; //! Primary vertex estimated using ESD tracks | |
585 | AliMultiplicity *fSPDMult; //! SPD tracklet multiplicity | |
586 | AliESDCaloTrigger* fPHOSTrigger; //! PHOS Trigger information | |
587 | AliESDCaloTrigger* fEMCALTrigger; //! PHOS Trigger information | |
bd95bae7 | 588 | AliESDACORDE *fESDACORDE; //! ACORDE ESD object caontaining bit pattern |
5e319bd5 | 589 | AliESDAD *fESDAD; //! AD ESD object caontaining bit pattern |
6c8e0967 | 590 | AliESDTrdTrigger *fTrdTrigger; //! TRD trigger information |
af885e0f | 591 | |
04d01397 | 592 | TClonesArray *fSPDPileupVertices;//! Pileup primary vertices reconstructed by SPD |
593 | TClonesArray *fTrkPileupVertices;//! Pileup primary vertices reconstructed using the tracks | |
af885e0f | 594 | TClonesArray *fTracks; //! ESD tracks |
595 | TClonesArray *fMuonTracks; //! MUON ESD tracks | |
fe0324de | 596 | TClonesArray *fMuonClusters; //! MUON ESD clusters |
597 | TClonesArray *fMuonPads; //! MUON ESD pads | |
d3eabe96 | 598 | TClonesArray *fMuonGlobalTracks; //! MUON+MFT ESD tracks // AU |
af885e0f | 599 | TClonesArray *fPmdTracks; //! PMD ESD tracks |
600 | TClonesArray *fTrdTracks; //! TRD ESD tracks (triggered) | |
52cd0cc0 | 601 | TClonesArray *fTrdTracklets; //! TRD tracklets (for trigger) |
af885e0f | 602 | TClonesArray *fV0s; //! V0 vertices |
603 | TClonesArray *fCascades; //! Cascade vertices | |
604 | TClonesArray *fKinks; //! Kinks | |
605 | TClonesArray *fCaloClusters; //! Calorimeter clusters for PHOS/EMCAL | |
e649177a | 606 | AliESDCaloCells *fEMCALCells; //! EMCAL cell info |
607 | AliESDCaloCells *fPHOSCells; //! PHOS cell info | |
8e1324ab | 608 | TClonesArray *fCosmicTracks; //! Tracks created by cosmics finder |
49436743 | 609 | TClonesArray *fESDTOFClusters; //! TOF clusters |
610 | TClonesArray *fESDTOFHits; //! TOF hits (used for clusters) | |
e073156e | 611 | TClonesArray *fESDTOFMatches; //! TOF matching info (with the reference to tracks) |
af885e0f | 612 | TClonesArray *fErrorLogs; //! Raw-data reading error messages |
613 | ||
fe0324de | 614 | Bool_t fOldMuonStructure; //! Flag if reading ESD with old MUON structure |
af885e0f | 615 | |
1bd10080 | 616 | AliESD *fESDOld; //! Old esd Structure |
617 | AliESDfriend *fESDFriendOld; //! Old friend esd Structure | |
60e8f114 | 618 | Bool_t fConnected; //! flag if leaves are alreday connected |
a2fbb067 | 619 | Bool_t fUseOwnList; //! Do not use the list from the esdTree but use the one created by this class |
d38034b8 | 620 | Bool_t fTracksConnected; //! flag if tracks have already pointer to event set |
60e8f114 | 621 | |
6989bff3 | 622 | static const char* fgkESDListName[kESDListN]; //! |
af885e0f | 623 | |
f858b00e | 624 | AliTOFHeader *fTOFHeader; //! event times (and sigmas) as estimated by TOF |
625 | // combinatorial algorithm. | |
626 | // It contains also TOF time resolution | |
627 | // and T0spread as written in OCDB | |
fba4b2e2 | 628 | AliCentrality *fCentrality; //! Centrality for AA collision |
ce7adfe9 | 629 | AliEventplane *fEventplane; //! Event plane for AA collision |
a8f382ab | 630 | |
0ca3804d | 631 | ULong64_t fDetectorStatus; // set detector event status bit for good event selection |
8bc95619 | 632 | UInt_t fDAQDetectorPattern; // Detector pattern from DAQ: bit 0 is SPD, bit 4 is TPC, etc. See event.h |
633 | UInt_t fDAQAttributes; // Third word of attributes from DAQ: bit 7 corresponds to HLT decision | |
a8f382ab | 634 | |
e073156e | 635 | ClassDef(AliESDEvent,23) //ESDEvent class |
af885e0f | 636 | }; |
637 | #endif | |
638 |