4 // This is the front-end for cut management and checking.
5 // It must be prepared by adding all required single cuts,
6 // and then with a logical expression which combines all cuts
7 // with the "AND", "OR" and "NOT" operators.
9 // author: M. Vala (martin.vala@cern.ch)
12 #ifndef ALIRSNCUTSET_H
13 #define ALIRSNCUTSET_H
16 #include <TObjArray.h>
18 #include "AliRsnCut.h"
21 class AliRsnExpression;
22 class AliRsnPairParticle;
25 class AliRsnCutSet : public TNamed
30 AliRsnCutSet(TString name);
31 AliRsnCutSet(const AliRsnCutSet ©);
34 void AddCut(AliRsnCut* cut);
37 Int_t GetIndexByCutName(TString s);
39 Bool_t IsValidScheme();
40 TString ShowCutScheme();
41 Int_t TestExpression(TString opt="short");
44 Bool_t IsSelected(AliRsnCut::ETarget type, AliRsnDaughter *daughter);
45 Bool_t IsSelected(AliRsnCut::ETarget type, AliRsnPairParticle *pair);
46 Bool_t IsSelected(AliRsnCut::ETarget type, AliRsnEvent *event);
47 Bool_t IsSelected(AliRsnCut::ETarget type, AliRsnEvent *ev1, AliRsnEvent *ev2);
49 void SetBoolValue(Bool_t theValue,Int_t index) { fBoolValues[index] = theValue; }
50 Bool_t GetBoolValue(Int_t index) const { return fBoolValues[index]; }
52 void SetCutScheme(const TString& theValue);
53 TString GetCutScheme() const { return fCutScheme; }
55 void SetCutSchemeIndexed(TString theValue);
56 TString GetCutSchemeIndexed();
58 TObjArray *GetCuts() { return &fCuts; }
62 AliRsnCutSet& operator=(const AliRsnCutSet& /*copy*/) {return (*this);}
64 TObjArray fCuts; // array of cuts
65 Int_t fNumOfCuts; // number of cuts
66 TString fCutScheme; // cut scheme
67 TString fCutSchemeIndexed; // cut scheme indexed
69 Bool_t *fBoolValues; //[fNumOfCuts]
70 Bool_t fIsScheme; // is scheme
72 AliRsnExpression *fExpression; // pointer to AliRsnExpression
74 ClassDef(AliRsnCutSet,1) // ROOT dictionary