#ifndef StntupleCut_hh #define StntupleCut_hh #include "TObject.h" #include "TString.h" #include "TH1.h" class TModule; class StntupleCut: public TObject { //----------------------------------------------------------------------------- // data members //----------------------------------------------------------------------------- protected: TString fName; Int_t fMode; // 0:normal, 1:veto (not implemented yet) Int_t fIndex; // index of the parameter in the array Double_t fPMin; Double_t fPMax; Int_t fNx; Double_t fXMin; Double_t fXMax; TH1F* fHist; // histogram before the cut Double_t fNInput; // [0]: input, [1]: output Double_t fNPassed; // [0]: input, [1]: output Double_t fNBelow; // N(events) < fPMin Double_t fNAbove; // N(events) >= fPMax //----------------------------------------------------------------------------- // methods //----------------------------------------------------------------------------- public: StntupleCut(); StntupleCut(const char* Name, TModule* Module, Int_t Index , Double_t PMin, Double_t PMax, Int_t NChannels, Double_t XMin, Double_t XMax, Int_t Mode = 0); virtual ~StntupleCut(); //----------------------------------------------------------------------------- // accessors //----------------------------------------------------------------------------- Double_t PMin () { return fPMin; } Double_t PMax () { return fPMax; } Double_t NInput () { return fNInput; } Double_t NPassed() { return fNPassed; } void GetParameters(Double_t& PMin, Double_t& PMax, Double_t& Nx, Double_t& XMin, Double_t& XMax); void SetParameters(Double_t PMin, Double_t PMax, Double_t Nx, Double_t XMin, Double_t XMax); void SetMode(int Mode) { fMode = Mode; } Int_t Passed(Double_t P); Int_t Passed(Double_t* P); virtual const char* GetName() const { return fName.Data(); } virtual Bool_t IsFolder() const { return kFALSE; } virtual void Browse(TBrowser* b); virtual void Clear(const char* Opt = ""); virtual void Print(const char* Opt = "") const; // *MENU* ClassDef(StntupleCut,1) }; #endif