1 #ifndef ALIPHOSFASTRECPARTICLE_H
2 #define ALIPHOSFASTRECPARTICLE_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
8 //_________________________________________________________________________
9 // A Particle modified by PHOS response and produced by AliPHOSvFast
10 // This is also a base class for AliPHOSRecParticle produced by AliPHOSPIDv1
11 // Defines the particle type
12 // To become a general class of AliRoot ?
14 //*-- Author: Yves Schutz (SUBATECH)
16 // --- ROOT system ---
19 #include "TParticle.h"
20 #include "AliESDtrack.h"
22 // --- Standard library ---
24 // --- AliRoot header files ---
26 class AliPHOSFastRecParticle : public TParticle {
30 AliPHOSFastRecParticle() ;
32 AliPHOSFastRecParticle(const AliPHOSFastRecParticle & rp) ; // ctor
33 AliPHOSFastRecParticle(const TParticle & p) ; // ctor
34 virtual ~AliPHOSFastRecParticle(){ } //dtor
36 virtual Int_t DistancetoPrimitive(Int_t px, Int_t py) ;
37 virtual void Draw(Option_t *option) ;
38 virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py) ;
39 Int_t GetIndexInList() const {
40 // returns the index of this in the list
43 virtual const Int_t GetNPrimaries() const {return 0 ;}
44 virtual const TParticle * GetPrimary(Int_t) const {return 0 ;}
45 const Int_t GetType() const {
46 // returns the type of the particle
50 void SetPIDBit(UInt_t fSet) {
51 // Set PID bit number fSet
55 Bool_t TestPIDBit(UInt_t fTest) const {
56 // Check PID bit number fTest
57 if (fType & (1<<fTest) ) return kTRUE ;
61 Bool_t IsPhoton (TString purity = "low") const;
62 Bool_t IsPi0 (TString purity = "low") const;
63 Bool_t IsElectron (TString purity = "low") const;
64 Bool_t IsHardPhoton () const;
65 Bool_t IsHardPi0 () const;
66 Bool_t IsHadron () const;
67 Bool_t IsChargedHadron () const;
68 Bool_t IsNeutralHadron () const;
69 Bool_t IsFastChargedHadron() const;
70 Bool_t IsSlowChargedHadron() const;
71 Bool_t IsFastNeutralHadron() const;
72 Bool_t IsSlowNeutralHadron() const;
73 Bool_t IsEleCon(TString purity = "low") const;
75 TString Name() const ;
76 virtual void Paint(Option_t * option="");
77 virtual void Print() const ;
79 void SetTof(Float_t tof) { fTof = tof ; }
80 Float_t ToF() const { return fTof ; }
81 void SetType(Int_t type) ;
83 void SetIndexInList(Int_t val) {
84 // sets the value of the index in the list
87 //This has to disappear
88 enum EParticleType { kTYPE = 8,
90 kNEUTRALEMFAST, kNEUTRALHAFAST, kNEUTRALEMSLOW, kNEUTRALHASLOW,
91 kCHARGEDEMFAST, kCHARGEDHAFAST, kCHARGEDEMSLOW, kCHARGEDHASLOW } ;
93 typedef TClonesArray FastRecParticlesList ;
97 Int_t fIndexInList ; // the index of this RecParticle in the list stored in TreeR (to be set by analysis)
98 Float_t fTof ; // time of fliht
99 Int_t fType ; // particle type obtained by "virtual" reconstruction
100 Double_t fPID[AliESDtrack::kSPECIESN] ; // PID probability densities
104 ClassDef(AliPHOSFastRecParticle,2) // Reconstructed Particle produced by the fast simulation
108 #endif // AliPHOSFASTRECPARTICLE_H