]> git.uio.no Git - u/mrichter/AliRoot.git/blob - HBTAN/AliHBTEvent.h
Update concerning changes in pair cut
[u/mrichter/AliRoot.git] / HBTAN / AliHBTEvent.h
1 #ifndef ALIHBTEvent_H
2 #define ALIHBTEvent_H
3 //This class sters HBT perticles for one event
4 //more info: http://alisoft.cern.ch/people/skowron/analyzer/index.html
5
6 #include <TObject.h>
7
8 class AliHBTParticle;
9 class TParticle;
10 class AliHBTEvent: public TObject
11  {
12   public:
13     AliHBTEvent();
14     virtual ~AliHBTEvent();
15     const static UInt_t fgkInitEventSize; //initial number of the array
16                                          //if expanded, this size is used also
17     AliHBTParticle* GetParticle(Int_t n);  //gets particle 
18     AliHBTParticle* GetParticleSafely(Int_t n); //gets particle with index check
19     
20     void    AddParticle(AliHBTParticle*); //adds particle to the event
21     void    AddParticle(TParticle*); //adds particle to the event
22     void    AddParticle(Int_t pdg, Double_t px, Double_t py, Double_t pz, Double_t etot,
23                         Double_t vx, Double_t vy, Double_t vz, Double_t time);
24     
25     Int_t   GetNumberOfParticles() const;
26     void   Reset(); //deletes all entries
27   protected:
28     AliHBTParticle ** fParticles; //!array of pointers to the particles
29     Int_t fNParticles; //!number of particles in Event
30     Int_t fSize;       //!current size of the array
31     
32     void  Expand();    //expands the array if necessary
33   private:
34     
35   public:
36     ClassDef(AliHBTEvent,1)
37  };
38 /**************************************************************************/ 
39  
40 inline 
41 AliHBTParticle* AliHBTEvent::GetParticle(Int_t n)
42  {
43  //Gets particle without boundary check
44    return fParticles[n];
45  }
46
47 /**************************************************************************/ 
48  
49 inline 
50 Int_t  AliHBTEvent::GetNumberOfParticles() const
51  {
52  //reurns number of particles in this event
53    return fNParticles;
54  }
55  
56 #endif