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 /* History of cvs commits:
13 //_________________________________________________________________________
14 // A Particle modified by PHOS response and produced by AliPHOSvFast
15 // This is also a base class for AliPHOSRecParticle produced by AliPHOSPIDv1
16 // Defines the particle type
17 // To become a general class of AliRoot ?
19 //*-- Author: Yves Schutz (SUBATECH)
21 // --- ROOT system ---
24 #include "TParticle.h"
25 #include "AliESDtrack.h"
27 // --- Standard library ---
29 // --- AliRoot header files ---
31 class AliPHOSFastRecParticle : public TParticle {
35 AliPHOSFastRecParticle() ;
37 AliPHOSFastRecParticle(const AliPHOSFastRecParticle & rp) ; // ctor
38 AliPHOSFastRecParticle(const TParticle & p) ; // ctor
39 virtual ~AliPHOSFastRecParticle(){ } //dtor
41 virtual Int_t DistancetoPrimitive(Int_t px, Int_t py) ;
42 virtual void Draw(Option_t *option) ;
43 virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py) ;
44 Int_t GetIndexInList() const {
45 // returns the index of this in the list
48 virtual Int_t GetNPrimaries() const {return 0 ;}
49 virtual const TParticle * GetPrimary(Int_t) const {return 0 ;}
50 Int_t GetType() const {
51 // returns the type of the particle
55 void SetPIDBit(UInt_t fSet) {
56 // Set PID bit number fSet
60 Bool_t TestPIDBit(UInt_t fTest) const {
61 // Check PID bit number fTest
62 if (fType & (1<<fTest) ) return kTRUE ;
66 Bool_t IsPhoton (TString purity = "low") const;
67 Bool_t IsPi0 (TString purity = "low") const;
68 Bool_t IsElectron (TString purity = "low") const;
69 Bool_t IsHardPhoton () const;
70 Bool_t IsHardPi0 () const;
71 Bool_t IsHadron () const;
72 Bool_t IsChargedHadron () const;
73 Bool_t IsNeutralHadron () const;
74 Bool_t IsFastChargedHadron() const;
75 Bool_t IsSlowChargedHadron() const;
76 Bool_t IsFastNeutralHadron() const;
77 Bool_t IsSlowNeutralHadron() const;
78 Bool_t IsEleCon(TString purity = "low") const;
80 TString Name() const ;
81 virtual void Paint(Option_t * option="");
82 virtual void Print(const Option_t * = "") const ;
84 void SetTof(Float_t tof) { fTof = tof ; }
85 Float_t ToF() const { return fTof ; }
86 void SetType(Int_t type) ;
88 void SetIndexInList(Int_t val) {
89 // sets the value of the index in the list
92 //This has to disappear
93 enum EParticleType { kTYPE = 8,
95 kNEUTRALEMFAST, kNEUTRALHAFAST, kNEUTRALEMSLOW, kNEUTRALHASLOW,
96 kCHARGEDEMFAST, kCHARGEDHAFAST, kCHARGEDEMSLOW, kCHARGEDHASLOW } ;
98 typedef TClonesArray FastRecParticlesList ;
102 Int_t fIndexInList ; // the index of this RecParticle in the list stored in TreeR (to be set by analysis)
103 Float_t fTof ; // time of fliht
104 Int_t fType ; // particle type obtained by "virtual" reconstruction
105 Double_t fPID[AliPID::kSPECIESN] ; // PID probability densities
109 ClassDef(AliPHOSFastRecParticle,2) // Reconstructed Particle produced by the fast simulation
113 #endif // AliPHOSFASTRECPARTICLE_H