]>
Commit | Line | Data |
---|---|---|
a5556ea5 | 1 | #ifndef ALIAOD_H |
2 | #define ALIAOD_H | |
3 | /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. * | |
4 | * See cxx source for full Copyright notice */ | |
5 | ||
6 | /* $Id$ */ | |
7 | ||
8 | ///////////////////////////////////////////////////////////// | |
9 | // | |
10 | // base class for AOD containers | |
11 | // | |
12 | ///////////////////////////////////////////////////////////// | |
13 | ||
14 | #include <TObject.h> | |
15 | #include <TObjArray.h> | |
16 | #include "AliAODParticle.h" | |
17 | ||
18 | class TParticle; | |
19 | ||
20 | class AliAOD: public TObject { | |
21 | public: | |
22 | AliAOD(){} | |
23 | virtual ~AliAOD() { Reset(); } | |
24 | ||
25 | virtual TObjArray* GetParticles() {return &fParticles;}; | |
26 | virtual Int_t GetNumberOfParticles() const {return fParticles.GetEntriesFast();} | |
27 | virtual AliAODParticle* GetParticle(Int_t index) const {return (AliAODParticle*) fParticles[index];} | |
28 | virtual void AddParticle(AliAODParticle* particle) {fParticles.Add(particle);}; | |
29 | virtual void AddParticle(TParticle* part, Int_t idx); //adds particle to the event | |
30 | virtual void AddParticle(Int_t pdg, Int_t idx, Double_t px, Double_t py, Double_t pz, Double_t etot, | |
31 | Double_t vx, Double_t vy, Double_t vz, Double_t time); | |
32 | ||
33 | virtual void Reset(); | |
34 | void SwapParticles(Int_t i, Int_t j);//swaps particles positions; used by AliReader::Blend | |
35 | private: | |
36 | TObjArray fParticles; // array of AOD particles, AliAOD is owner of particles | |
37 | ||
38 | ClassDef(AliAOD,1) // base class for AOD containers | |
39 | }; | |
40 | ||
41 | #endif |