]>
Commit | Line | Data |
---|---|---|
a73f33f0 | 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 */ | |
5 | ||
6 | /* $Id$ */ | |
7 | ||
702ab87e | 8 | /* History of cvs commits: |
9 | * | |
10 | * $Log$ | |
11 | */ | |
12 | ||
b2a60966 | 13 | //_________________________________________________________________________ |
14 | // A Particle modified by PHOS response and produced by AliPHOSvFast | |
3f6cb8ae | 15 | // This is also a base class for AliPHOSRecParticle produced by AliPHOSPIDv1 |
16 | // Defines the particle type | |
b2a60966 | 17 | // To become a general class of AliRoot ? |
3f6cb8ae | 18 | //-- |
b2a60966 | 19 | //*-- Author: Yves Schutz (SUBATECH) |
a73f33f0 | 20 | |
21 | // --- ROOT system --- | |
22 | ||
0fbb8738 | 23 | class TClonesArray; |
a73f33f0 | 24 | #include "TParticle.h" |
cc1fe362 | 25 | #include "AliESDtrack.h" |
a73f33f0 | 26 | |
27 | // --- Standard library --- | |
28 | ||
29 | // --- AliRoot header files --- | |
30 | ||
a73f33f0 | 31 | class AliPHOSFastRecParticle : public TParticle { |
cfeebab6 | 32 | |
88714635 | 33 | public: |
a73f33f0 | 34 | |
03c03c49 | 35 | AliPHOSFastRecParticle() ; |
cfeebab6 | 36 | |
a73f33f0 | 37 | AliPHOSFastRecParticle(const AliPHOSFastRecParticle & rp) ; // ctor |
38 | AliPHOSFastRecParticle(const TParticle & p) ; // ctor | |
3f6cb8ae | 39 | virtual ~AliPHOSFastRecParticle(){ } //dtor |
40 | ||
a73f33f0 | 41 | virtual Int_t DistancetoPrimitive(Int_t px, Int_t py) ; |
42 | virtual void Draw(Option_t *option) ; | |
b2a60966 | 43 | virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py) ; |
88714635 | 44 | Int_t GetIndexInList() const { |
45 | // returns the index of this in the list | |
46 | return fIndexInList ; | |
47 | } | |
17323043 | 48 | virtual Int_t GetNPrimaries() const {return 0 ;} |
90cceaf6 | 49 | virtual const TParticle * GetPrimary(Int_t) const {return 0 ;} |
17323043 | 50 | Int_t GetType() const { |
88714635 | 51 | // returns the type of the particle |
52 | return fType ; | |
53 | } | |
6a40c29e | 54 | |
3f6cb8ae | 55 | void SetPIDBit(UInt_t fSet) { |
56 | // Set PID bit number fSet | |
57 | fType |= (1<<fSet) ; | |
58 | } | |
cfeebab6 | 59 | |
3f6cb8ae | 60 | Bool_t TestPIDBit(UInt_t fTest) const { |
61 | // Check PID bit number fTest | |
62 | if (fType & (1<<fTest) ) return kTRUE ; | |
63 | else return kFALSE ; | |
a3d4377c | 64 | } |
794c2bc3 | 65 | |
3d8b8082 | 66 | Bool_t IsPhoton (TString purity = "low") const; |
67 | Bool_t IsPi0 (TString purity = "low") const; | |
68 | Bool_t IsElectron (TString purity = "low") const; | |
e3817e5f | 69 | Bool_t IsHardPhoton () const; |
70 | Bool_t IsHardPi0 () const; | |
3f6cb8ae | 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; | |
948a4b24 | 78 | Bool_t IsEleCon(TString purity = "low") const; |
a3d4377c | 79 | |
14f6a871 | 80 | TString Name() const ; |
a73f33f0 | 81 | virtual void Paint(Option_t * option=""); |
702ab87e | 82 | virtual void Print(const Option_t * = "") const ; |
6a40c29e | 83 | |
43dc5270 | 84 | void SetTof(Float_t tof) { fTof = tof ; } |
85 | Float_t ToF() const { return fTof ; } | |
14f6a871 | 86 | void SetType(Int_t type) ; |
cfeebab6 | 87 | |
88714635 | 88 | void SetIndexInList(Int_t val) { |
89 | // sets the value of the index in the list | |
90 | fIndexInList = val ; | |
cfeebab6 | 91 | } |
92 | //This has to disappear | |
43dc5270 | 93 | enum EParticleType { kTYPE = 8, |
94 | kUNDEFINED=-1, | |
a3d4377c | 95 | kNEUTRALEMFAST, kNEUTRALHAFAST, kNEUTRALEMSLOW, kNEUTRALHASLOW, |
96 | kCHARGEDEMFAST, kCHARGEDHAFAST, kCHARGEDEMSLOW, kCHARGEDHASLOW } ; | |
97 | ||
c0d5b57d | 98 | typedef TClonesArray FastRecParticlesList ; |
cfeebab6 | 99 | |
88714635 | 100 | protected: |
a73f33f0 | 101 | |
83974468 | 102 | Int_t fIndexInList ; // the index of this RecParticle in the list stored in TreeR (to be set by analysis) |
43dc5270 | 103 | Float_t fTof ; // time of fliht |
83974468 | 104 | Int_t fType ; // particle type obtained by "virtual" reconstruction |
304864ab | 105 | Double_t fPID[AliPID::kSPECIESN] ; // PID probability densities |
cc1fe362 | 106 | |
88714635 | 107 | private: |
108 | ||
794c2bc3 | 109 | ClassDef(AliPHOSFastRecParticle,2) // Reconstructed Particle produced by the fast simulation |
a73f33f0 | 110 | |
111 | }; | |
112 | ||
113 | #endif // AliPHOSFASTRECPARTICLE_H |