AliPhysics  v5-07-18-02 (20ec537)
 All Classes Namespaces Files Functions Variables Enumerations Enumerator Macros
AliParticleContainer.h
Go to the documentation of this file.
1 #ifndef AliParticleContainer_H
2 #define AliParticleContainer_H
3 
4 // $Id$
5 
6 class AliVEvent;
7 class AliVParticle;
8 
9 #include "AliAODMCParticle.h"
10 
11 #include "AliEmcalContainer.h"
12 
14  public:
16  AliParticleContainer(const char *name);
17  virtual ~AliParticleContainer(){;}
18 
19  Bool_t AcceptParticle(AliVParticle *vp) ;
20  Double_t GetParticlePtCut() const { return fParticlePtCut; }
21  Double_t GetParticleEtaMin() const { return fParticleMinEta; }
22  Double_t GetParticleEtaMax() const { return fParticleMaxEta; }
23  Double_t GetParticlePhiMin() const { return fParticleMinPhi; }
24  Double_t GetParticlePhiMax() const { return fParticleMaxPhi; }
25  AliVParticle *GetLeadingParticle(const char* opt="") ;
26  AliVParticle *GetParticle(Int_t i) const;
27  AliVParticle *GetAcceptParticle(Int_t i) ;
28  AliVParticle *GetParticleWithLabel(Int_t lab) const;
29  AliVParticle *GetAcceptParticleWithLabel(Int_t lab) ;
30  AliVParticle *GetNextAcceptParticle(Int_t i=-1) ;
31  AliVParticle *GetNextParticle(Int_t i=-1) ;
32  void GetMomentum(TLorentzVector &mom, Int_t i) const;
33  Int_t GetNParticles() const {return GetNEntries();}
34  Int_t GetNAcceptedParticles() ;
35 
36  void SetArray(AliVEvent *event);
37 
38  void SetClassName(const char *clname);
39  void SetMCTrackBitMap(UInt_t m) { fMCTrackBitMap = m ; }
40  void SetMinMCLabel(Int_t s) { fMinMCLabel = s ; }
41  void SetMinMCLabelAccept(Int_t s) { fMinMCLabelAccept= s ; }
42  void SetParticlePtCut(Double_t cut) { fParticlePtCut = cut ; }
43  void SetParticleEtaLimits(Double_t min, Double_t max) { fParticleMaxEta = max ; fParticleMinEta = min ; }
44  void SetParticlePhiLimits(Double_t min, Double_t max, Double_t offset=0.) { fParticleMaxPhi = max ; fParticleMinPhi = min ; fPhiOffset = offset;}
46  void SetTrackBitMap(UInt_t m) { fTrackBitMap = m ; }
47  void SetMCFlag(UInt_t m) { fMCFlag = m ; }
48  void SelectHIJING(Bool_t s) { if (s) fGeneratorIndex = 0; else fGeneratorIndex = -1; }
49  void SetGeneratorIndex(Short_t i) { fGeneratorIndex = i ; }
50  void SelectPhysicalPrimaries(Bool_t s) { if (s) fMCFlag |= AliAODMCParticle::kPhysicalPrim ;
51  else fMCFlag &= ~AliAODMCParticle::kPhysicalPrim ; }
52  void SetCharge(Short_t c) { fCharge = c ; }
54 
55  protected:
56  Double_t fParticlePtCut; // cut on particle pt
57  Double_t fParticleMinEta; // cut on particle eta
58  Double_t fParticleMaxEta; // cut on particle eta
59  Double_t fParticleMinPhi; // cut on particle phi
60  Double_t fParticleMaxPhi; // cut on particle phi
61  Double_t fPhiOffset; // phi offset
62  Double_t fMinDistanceTPCSectorEdge; // require minimum distance to edge of TPC sector edge
63  UInt_t fTrackBitMap; // bit map of accepted tracks (non MC)
64  UInt_t fMCTrackBitMap; // bit map of accepted MC tracks
65  Int_t fMinMCLabel; // minimum MC label value for the tracks/clusters being considered MC particles
66  Int_t fMinMCLabelAccept; // minimum MC label value to accept particle
67  UInt_t fMCFlag; // select MC particles with flags
68  Short_t fGeneratorIndex; // select MC particles with generator index (default = -1 = switch off selection)
69  Short_t fCharge; // select particles with charge=fCharge
70  Bool_t fFilterHybridTracks; // filter hybrid tracks (only works with AOD tracks)
71 
72  private:
73  AliParticleContainer(const AliParticleContainer& obj); // copy constructor
74  AliParticleContainer& operator=(const AliParticleContainer& other); // assignment
75 
77 
78 };
79 
80 #endif
81 
void SetParticlePtCut(Double_t cut)
AliVParticle * GetParticleWithLabel(Int_t lab) const
AliParticleContainer & operator=(const AliParticleContainer &other)
void SetClassName(const char *clname)
Int_t GetNParticles() const
void SelectPhysicalPrimaries(Bool_t s)
Bool_t AcceptParticle(AliVParticle *vp)
Double_t GetParticleEtaMin() const
void SetFilterHybridTracks(Bool_t f)
void SetTrackBitMap(UInt_t m)
AliVParticle * GetAcceptParticleWithLabel(Int_t lab)
void SetMinMCLabelAccept(Int_t s)
void SetArray(AliVEvent *event)
AliVParticle * GetParticle(Int_t i) const
AliVParticle * GetAcceptParticle(Int_t i)
AliVParticle * GetLeadingParticle(const char *opt="")
void GetMomentum(TLorentzVector &mom, Int_t i) const
AliVParticle * GetNextAcceptParticle(Int_t i=-1)
Double_t GetParticlePtCut() const
AliVParticle * GetNextParticle(Int_t i=-1)
ClassDef(AliParticleContainer, 7)
void SetParticleEtaLimits(Double_t min, Double_t max)
Double_t GetParticlePhiMax() const
void SetMCTrackBitMap(UInt_t m)
Double_t GetParticleEtaMax() const
void SetGeneratorIndex(Short_t i)
Double_t GetParticlePhiMin() const
void SetParticlePhiLimits(Double_t min, Double_t max, Double_t offset=0.)
Int_t GetNEntries() const
void SetMinDistanceTPCSectorEdge(Double_t min)