]> git.uio.no Git - u/mrichter/AliRoot.git/blame - ANALYSIS/EventMixing/AliMixEventCutObj.h
reverting...
[u/mrichter/AliRoot.git] / ANALYSIS / EventMixing / AliMixEventCutObj.h
CommitLineData
c5e33610 1//
2// Class AliMixEventCutObj
3//
4// AliMixEventCutObj object contains information about one cut on for event mixing
5// used by AliMixEventPool class
6//
b425275c 7// authors:
c5e33610 8// Martin Vala (martin.vala@cern.ch)
9//
10
11#ifndef ALIMIXEVENTCUTOBJ_H
12#define ALIMIXEVENTCUTOBJ_H
13
14#include <TObject.h>
298831c0 15#include <TString.h>
16
c5e33610 17class AliVEvent;
18class AliAODEvent;
19class AliESDEvent;
b425275c 20class AliMixEventCutObj : public TObject {
c5e33610 21public:
35e08f92 22 enum EEPAxis_t {kMultiplicity = 0, kZVertex = 1, kNumberV0s = 2, kNumberTracklets = 3, kCentrality = 4, kEventPlane = 5, kAllEventAxis = 6};
b425275c 23
35e08f92 24 AliMixEventCutObj(AliMixEventCutObj::EEPAxis_t type = kMultiplicity, Float_t min = 0.0, Float_t max = 0.0, Float_t step = 1.0, const char *opt = "");
b425275c 25 AliMixEventCutObj(const AliMixEventCutObj &obj);
26 AliMixEventCutObj &operator=(const AliMixEventCutObj &obj);
27
28 virtual void Print(const Option_t *) const;
29 void PrintCurrentInterval();
35e08f92 30 void PrintValues(AliVEvent *main, AliVEvent *mix);
b425275c 31 void Reset();
32 void AddStep();
33
34 Bool_t HasMore() const;
c5e33610 35
b425275c 36 Int_t GetNumberOfBins() const;
37 Float_t GetMin() const { return fCurrentVal; }
38 Float_t GetMax() const { return fCurrentVal + fCutStep - fCutSmallVal; }
39 Float_t GetStep() const { return fCutStep; }
40 Short_t GetType() const { return fCutType; }
41 Int_t GetBinNumber(Float_t num) const;
42 Int_t GetIndex(AliVEvent *ev);
24dc85b1 43 Double_t GetValue(AliVEvent *ev);
44 Double_t GetValue(AliESDEvent *ev);
45 Double_t GetValue(AliAODEvent *ev);
46
b425275c 47 const char *GetCutName(Int_t index = -1) const;
48
49 void SetCurrentValueToIndex(Int_t index);
50
51private:
52 Int_t fCutType; // cut type
298831c0 53 TString fCutOpt; // cut option string
b425275c 54 Float_t fCutMin; // cut min
55 Float_t fCutMax; // cut max
56 Float_t fCutStep; // cut step
57 Float_t fCutSmallVal; // small value
c5e33610 58
b425275c 59 Float_t fCurrentVal; // current value
c5e33610 60
298831c0 61 ClassDef(AliMixEventCutObj, 2)
c5e33610 62};
63
64#endif