GSI Object Oriented Online Offline (Go4)  GO4-5.3.2
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
TGo4WinCond.h
Go to the documentation of this file.
1 // $Id: TGo4WinCond.h 1922 2016-06-13 10:23:16Z adamczew $
2 //-----------------------------------------------------------------------
3 // The GSI Online Offline Object Oriented (Go4) Project
4 // Experiment Data Processing at EE department, GSI
5 //-----------------------------------------------------------------------
6 // Copyright (C) 2000- GSI Helmholtzzentrum für Schwerionenforschung GmbH
7 // Planckstr. 1, 64291 Darmstadt, Germany
8 // Contact: http://go4.gsi.de
9 //-----------------------------------------------------------------------
10 // This software can be used under the license agreements as stated
11 // in Go4License.txt file which is part of the distribution.
12 //-----------------------------------------------------------------------
13 
14 #ifndef TGO4WINCOND_H
15 #define TGO4WINCOND_H
16 
17 #include "TGo4Condition.h"
18 
19 class TH1;
20 
21 class TGo4WinCond : public TGo4Condition {
22  public:
23  TGo4WinCond();
24 
25  TGo4WinCond(const char* name, const char* title = "Go4 window condition");
26 
27  virtual ~TGo4WinCond();
28 
31 
35  virtual void SetPainter(TGo4ConditionPainter* painter);
36 
37 // virtual void SetValues() {}
38 // virtual void SetValues(TCutG * newcut) {}
39 // virtual void SetValues(Double_t * x, Double_t * y, Int_t len) {}
40 
42  virtual void SetValues(Double_t low1, Double_t up1);
43 
45  virtual void SetValues(Double_t low1, Double_t up1, Double_t low2, Double_t up2);
46 
47 // virtual Bool_t Test() { return true; }
48 // virtual Bool_t Test(Bool_t on) { return true; }
49 
51  virtual Bool_t Test(Double_t v1);
52 
55  virtual Bool_t Test(Double_t v1, Double_t v2);
56 
58  virtual void GetValues(Int_t & dim, Double_t & x1, Double_t & y1, Double_t & x2, Double_t & y2);
59 
60  inline virtual Double_t GetXLow(){return fLow1;}
61  inline virtual Double_t GetXUp() {return fUp1;}
62  inline virtual Double_t GetYLow(){return fLow2;}
63  inline virtual Double_t GetYUp() {return fUp2;}
64 
66  virtual void PrintCondition(Bool_t full = kTRUE);
67 
69  Bool_t UpdateFrom(TGo4Condition * cond, Bool_t counts);
70 
72  virtual Bool_t UpdateFromUrl(const char* rest_url_opt);
73 
74 
76  virtual Double_t GetIntegral(TH1* histo, Option_t* opt="");
77 
79  virtual Double_t GetMean(TH1* histo, Int_t axis=1);
80 
82  virtual Double_t GetRMS(TH1* histo, Int_t axis=1);
83 
85  virtual Double_t GetSkewness(TH1* histo, Int_t axis=1);
86 
88  virtual Double_t GetCurtosis(TH1* histo, Int_t axis=1);
89 
91  virtual Double_t GetXMax(TH1* histo);
92 
94  virtual Double_t GetYMax(TH1* histo);
95 
97  virtual Double_t GetCMax(TH1* histo);
98 
99  virtual Bool_t IsPolygonType();
100 
101  virtual Int_t GetMemorySize();
102 
104  virtual void SavePrimitive(std::ostream& fs, Option_t* = "");
105 
106 
108  static TString fgxURL_XLOW;
110  static TString fgxURL_XUP;
111 
113  static TString fgxURL_YLOW;
115  static TString fgxURL_YUP;
116 
117 
118  private:
119 
121  Double_t fLow1;
122 
124  Double_t fUp1;
125 
127  Double_t fLow2;
128 
130  Double_t fUp2;
131 
133  Int_t fiSaveXMin;
134 
136  Int_t fiSaveXMax;
137 
139  Int_t fiSaveYMin;
140 
142  Int_t fiSaveYMax;
143 
145  void SetHistogramRanges(TH1* histo);
146 
148  void RestoreHistogramRanges(TH1* histo);
149 
150  ClassDef(TGo4WinCond,7)
151 };
152 
153 #endif //TGO4WINCOND_H
static TString fgxURL_YLOW
Definition: TGo4WinCond.h:113
virtual Double_t GetYLow()
Definition: TGo4WinCond.h:62
virtual Double_t GetIntegral(TH1 *histo, Option_t *opt="")
Int_t fiSaveYMax
Definition: TGo4WinCond.h:142
virtual void SavePrimitive(std::ostream &fs, Option_t *="")
Int_t fiSaveXMin
Definition: TGo4WinCond.h:133
virtual void PrintCondition(Bool_t full=kTRUE)
Double_t fUp2
Definition: TGo4WinCond.h:130
virtual Double_t GetYMax(TH1 *histo)
virtual Double_t GetSkewness(TH1 *histo, Int_t axis=1)
virtual Double_t GetCMax(TH1 *histo)
virtual Double_t GetCurtosis(TH1 *histo, Int_t axis=1)
virtual Double_t GetXUp()
Definition: TGo4WinCond.h:61
virtual void GetValues(Int_t &dim, Double_t &x1, Double_t &y1, Double_t &x2, Double_t &y2)
virtual void SetValues()
virtual TGo4ConditionPainter * CreatePainter()
Int_t fiSaveYMin
Definition: TGo4WinCond.h:139
static TString fgxURL_XUP
Definition: TGo4WinCond.h:110
virtual Bool_t IsPolygonType()
void SetHistogramRanges(TH1 *histo)
virtual Double_t GetMean(TH1 *histo, Int_t axis=1)
Int_t fiSaveXMax
Definition: TGo4WinCond.h:136
Double_t fLow1
Definition: TGo4WinCond.h:121
Double_t fLow2
Definition: TGo4WinCond.h:127
static TString fgxURL_XLOW
Definition: TGo4WinCond.h:108
virtual void SetPainter(TGo4ConditionPainter *painter)
static TString fgxURL_YUP
Definition: TGo4WinCond.h:115
virtual Int_t GetMemorySize()
Double_t fUp1
Definition: TGo4WinCond.h:124
virtual Double_t GetXLow()
Definition: TGo4WinCond.h:60
virtual Double_t GetYUp()
Definition: TGo4WinCond.h:63
virtual Bool_t Test()
virtual Double_t GetXMax(TH1 *histo)
void RestoreHistogramRanges(TH1 *histo)
Bool_t UpdateFrom(TGo4Condition *cond, Bool_t counts)
virtual Double_t GetRMS(TH1 *histo, Int_t axis=1)
virtual ~TGo4WinCond()
Definition: TGo4WinCond.cxx:63
virtual Bool_t UpdateFromUrl(const char *rest_url_opt)