AliPhysics  9fe175b (9fe175b)
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
AliClusterContainer.h
Go to the documentation of this file.
1 #ifndef AliClusterContainer_H
2 #define AliClusterContainer_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4  * See cxx source for full Copyright notice */
5 
6 class TLorentzVector;
7 
8 class AliVEvent;
9 
10 #include <TArrayI.h>
11 #include <AliVCluster.h>
12 
13 #include "AliEmcalContainer.h"
14 
15 #if !(defined(__CINT__) || defined(__MAKECINT__))
18 #endif
19 
29 class AliClusterContainer : public AliEmcalContainer {
30  public:
31  typedef enum AliVCluster::VCluUserDefEnergy_t VCluUserDefEnergy_t;
32 
34  AliClusterContainer(const char *name);
35  virtual ~AliClusterContainer(){;}
36 
37  virtual TObject *operator[] (int index) const { return GetCluster(index); }
38 
39  virtual Bool_t AcceptObject(Int_t i, UInt_t &rejectionReason) const { return AcceptCluster(i, rejectionReason);}
40  virtual Bool_t AcceptObject(const TObject* obj, UInt_t &rejectionReason) const { return AcceptCluster(dynamic_cast<const AliVCluster*>(obj), rejectionReason);}
41  virtual Bool_t AcceptCluster(Int_t i, UInt_t &rejectionReason) const;
42  virtual Bool_t AcceptCluster(const AliVCluster* vp, UInt_t &rejectionReason) const;
43  virtual Bool_t ApplyClusterCuts(const AliVCluster* clus, UInt_t &rejectionReason) const;
44  AliVCluster *GetAcceptCluster(Int_t i) const;
45  AliVCluster *GetAcceptClusterWithLabel(Int_t lab) const;
46  void SetClusECut(Double_t cut) { SetMinE(cut) ; }
47  void SetClusPtCut(Double_t cut) { SetMinPt(cut) ; }
48  Double_t GetClusPtCut() const { return GetMinPt(); }
49  AliVCluster *GetCluster(Int_t i) const;
50  AliVCluster *GetClusterWithLabel(Int_t lab) const;
51  AliVCluster *GetLeadingCluster(const char* opt="") ;
52  Bool_t GetMomentum(TLorentzVector &mom, const AliVCluster* vc, Double_t mass) const;
53  Bool_t GetMomentum(TLorentzVector &mom, const AliVCluster* clus) const;
54  Bool_t GetMomentum(TLorentzVector &mom, Int_t i) const;
55  Bool_t GetAcceptMomentum(TLorentzVector &mom, Int_t i) const;
56  Bool_t GetNextMomentum(TLorentzVector &mom);
57  Bool_t GetNextAcceptMomentum(TLorentzVector &mom);
58  AliVCluster *GetNextAcceptCluster();
59  AliVCluster *GetNextCluster();
60  Int_t GetNClusters() const { return GetNEntries(); }
61  Int_t GetNAcceptedClusters() const;
62  void SetClusTimeCut(Double_t min, Double_t max) { fClusTimeCutLow = min ; fClusTimeCutUp = max ; }
63  void SetMinMCLabel(Int_t s) { fMinMCLabel = s ; }
64  void SetMaxMCLabel(Int_t s) { fMaxMCLabel = s ; }
65  void SetMCLabelRange(Int_t min, Int_t max) { SetMinMCLabel(min) ; SetMaxMCLabel(max) ; }
66  void SetExoticCut(Bool_t e) { fExoticCut = e ; }
67 
68  void SetClusUserDefEnergyCut(Int_t t, Double_t cut);
69  Double_t GetClusUserDefEnergyCut(Int_t t) const;
70 
71  void SetClusNonLinCorrEnergyCut(Double_t cut) { SetClusUserDefEnergyCut(AliVCluster::kNonLinCorr, cut); }
72  void SetClusHadCorrEnergyCut(Double_t cut) { SetClusUserDefEnergyCut(AliVCluster::kHadCorr, cut) ; }
74 
76 
77  const char* GetTitle() const;
78 
79 #if !(defined(__CINT__) || defined(__MAKECINT__))
80  const AliClusterIterableContainer all() const;
82 
85 
86 #endif
87 
88  protected:
89 
90  Double_t fClusTimeCutLow;
91  Double_t fClusTimeCutUp;
92  Bool_t fExoticCut;
93  Double_t fUserDefEnergyCut[AliVCluster::kLastUserDefEnergy+1];
95 
96  private:
97  AliClusterContainer(const AliClusterContainer& obj); // copy constructor
98  AliClusterContainer& operator=(const AliClusterContainer& other); // assignment
99 
101  ClassDef(AliClusterContainer,5);
103 };
104 
114 int TestClusterContainerIterator(const AliClusterContainer *const cont, int iteratorType = 0, bool verbose = false);
115 
116 #endif
117 
AliVCluster * GetAcceptClusterWithLabel(Int_t lab) const
virtual Bool_t ApplyClusterCuts(const AliVCluster *clus, UInt_t &rejectionReason) const
Bool_t GetNextAcceptMomentum(TLorentzVector &mom)
const char * GetTitle() const
AliClusterContainer & operator=(const AliClusterContainer &other)
EMCALIterableContainer::AliEmcalIterableContainerT< AliVCluster, EMCALIterableContainer::operator_star_object< AliVCluster > > AliClusterIterableContainer
Bool_t GetNextMomentum(TLorentzVector &mom)
const AliClusterIterableMomentumContainer accepted_momentum() const
Double_t mass
Double_t fClusTimeCutLow
low time cut for clusters
Double_t fUserDefEnergyCut[AliVCluster::kLastUserDefEnergy+1]
cut on the energy of the cluster after higher level corrections (see AliVCluster.h) ...
void SetClusUserDefEnergyCut(Int_t t, Double_t cut)
AliVCluster * GetLeadingCluster(const char *opt="")
Double_t GetClusUserDefEnergyCut(Int_t t) const
Int_t GetDefaultClusterEnergy() const
const AliClusterIterableContainer all() const
enum AliVCluster::VCluUserDefEnergy_t VCluUserDefEnergy_t
virtual Bool_t AcceptObject(Int_t i, UInt_t &rejectionReason) const
Double_t GetClusPtCut() const
void SetClusNonLinCorrEnergyCut(Double_t cut)
virtual Bool_t AcceptCluster(Int_t i, UInt_t &rejectionReason) const
AliVCluster * GetAcceptCluster(Int_t i) const
Int_t GetNClusters() const
Int_t GetNAcceptedClusters() const
const AliClusterIterableContainer accepted() const
Double_t fClusTimeCutUp
up time cut for clusters
AliVCluster * GetCluster(Int_t i) const
Bool_t fExoticCut
reject clusters marked as "exotic"
AliVCluster * GetNextCluster()
EMCALIterableContainer::AliEmcalIterableContainerT< AliVCluster, EMCALIterableContainer::operator_star_pair< AliVCluster > > AliClusterIterableMomentumContainer
void SetMaxMCLabel(Int_t s)
const AliClusterIterableMomentumContainer all_momentum() const
Bool_t GetAcceptMomentum(TLorentzVector &mom, Int_t i) const
void SetMinMCLabel(Int_t s)
AliVCluster * GetClusterWithLabel(Int_t lab) const
int TestClusterContainerIterator(const AliClusterContainer *const cont, int iteratorType=0, bool verbose=false)
virtual TObject * operator[](int index) const
void SetMCLabelRange(Int_t min, Int_t max)
Bool_t GetMomentum(TLorentzVector &mom, const AliVCluster *vc, Double_t mass) const
void SetClusPtCut(Double_t cut)
virtual Bool_t AcceptObject(const TObject *obj, UInt_t &rejectionReason) const
Int_t fDefaultClusterEnergy
default cluster energy: -1 for clus->E(); otherwise clus->GetUserDefEnergy(fDefaultClusterEnergy) ...
void SetClusECut(Double_t cut)
void SetDefaultClusterEnergy(Int_t d)
void SetClusTimeCut(Double_t min, Double_t max)
Container structure for EMCAL clusters.
AliVCluster * GetNextAcceptCluster()
void SetExoticCut(Bool_t e)
void SetClusHadCorrEnergyCut(Double_t cut)