Pass() renamed to Rejected()
[u/mrichter/AliRoot.git] / ANALYSIS / AliEventBaseCut.h
CommitLineData
b4fb427e 1#ifndef ALIEVENTBASECUT_H
2#define ALIEVENTBASECUT_H
b26900d0 3//________________________________
4///////////////////////////////////////////////////////////
5//
b4fb427e 6// class AliEventBaseCut
b26900d0 7//
8// Base class for cauts that checks only one event property
9//
10// Piotr.Skowronski@cern.ch
11//
12///////////////////////////////////////////////////////////
13
14#include "TObject.h"
15
a5556ea5 16class AliAOD;
b26900d0 17
a94c0b01 18enum EEventCutProperty
0d8a4589 19 {
20 kPrimVertexXCut,
21 kPrimVertexYCut,
22 kPrimVertexZCut,
a94c0b01 23 kNChargedCut,
24 kNone
0d8a4589 25 };
26
b4fb427e 27class AliEventBaseCut: public TObject
b26900d0 28{
29 public:
b4fb427e 30 AliEventBaseCut();
a94c0b01 31 AliEventBaseCut(Double_t min,Double_t max, EEventCutProperty prop = kNone);
b4fb427e 32 virtual ~AliEventBaseCut(){}
cea0a066 33 virtual Bool_t Rejected(AliAOD* aod) const;//returns kTRUE if rejected
a94c0b01 34 virtual void SetRange(Double_t min, Double_t max){fMin = min; fMax = max;}
35
36 virtual EEventCutProperty GetProperty()const{return fProperty;}
37
b26900d0 38 protected:
a5556ea5 39 virtual Double_t GetValue(AliAOD* aod) const = 0;
b26900d0 40
41 Double_t fMin;//Minimum value
42 Double_t fMax;//Maximum value
a94c0b01 43 EEventCutProperty fProperty;//Defines the type of the cut - used by the setters cut
44
b26900d0 45 private:
b4fb427e 46 ClassDef(AliEventBaseCut,1)
b26900d0 47};
48
0d8a4589 49/************************************************************/
50
b4fb427e 51class AliPrimVertexXCut: public AliEventBaseCut
0d8a4589 52{
53 public:
a94c0b01 54 AliPrimVertexXCut():AliEventBaseCut(0,0,kPrimVertexXCut){}
55 AliPrimVertexXCut(Double_t min,Double_t max):AliEventBaseCut(min,max,kPrimVertexXCut){}
0d8a4589 56 virtual ~AliPrimVertexXCut(){}
57 protected:
58 Double_t GetValue(AliAOD* aod) const;
59
60 private:
61 ClassDef(AliPrimVertexXCut,1)
62};
63/************************************************************/
64
b4fb427e 65class AliPrimVertexYCut: public AliEventBaseCut
0d8a4589 66{
67 public:
a94c0b01 68 AliPrimVertexYCut():AliEventBaseCut(0,0,kPrimVertexYCut){}
69 AliPrimVertexYCut(Double_t min,Double_t max):AliEventBaseCut(min,max,kPrimVertexYCut){}
0d8a4589 70 virtual ~AliPrimVertexYCut(){}
71
72 protected:
73 Double_t GetValue(AliAOD* aod) const;
74
75 private:
76 ClassDef(AliPrimVertexYCut,1)
77};
78/************************************************************/
79
b4fb427e 80class AliPrimVertexZCut: public AliEventBaseCut
0d8a4589 81{
82 public:
a94c0b01 83 AliPrimVertexZCut():AliEventBaseCut(0,0,kPrimVertexZCut){}
84 AliPrimVertexZCut(Double_t min,Double_t max):AliEventBaseCut(min,max,kPrimVertexZCut){}
0d8a4589 85 virtual ~AliPrimVertexZCut(){}
86 protected:
87 Double_t GetValue(AliAOD* aod) const;
88
89 private:
90 ClassDef(AliPrimVertexZCut,1)
91};
92
93
94/************************************************************/
95
b4fb427e 96class AliNChargedCut: public AliEventBaseCut
0d8a4589 97{
98 public:
a94c0b01 99 AliNChargedCut():AliEventBaseCut(0,0,kNChargedCut){}
0d8a4589 100 AliNChargedCut(Double_t min, Double_t max, Double_t etamin = -10.0, Double_t etamax = 10.0):
a94c0b01 101 AliEventBaseCut(min,max,kNChargedCut),fEtaMin(etamin),fEtaMax(etamax){}
0d8a4589 102 virtual ~AliNChargedCut(){}
a94c0b01 103
104 void SetEtaRange(Double_t min,Double_t max){fEtaMin = min;fEtaMax = max;}
0d8a4589 105 protected:
106 Double_t GetValue(AliAOD* aod) const;
107 Double_t fEtaMin;//Defines max of eta range where mult is caclulated
108 Double_t fEtaMax;//Defines min of eta range where mult is caclulated
109
110 private:
111 ClassDef(AliNChargedCut,1)
112};
113
114
b26900d0 115#endif