Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

TGo4PolyCond Class Reference

#include <TGo4PolyCond.h>

Inheritance diagram for TGo4PolyCond:

TGo4Condition List of all members.

Public Methods

 TGo4PolyCond ()
virtual ~TGo4PolyCond ()
 TGo4PolyCond (const Text_t *name)
 TGo4PolyCond (const Text_t *name, const Text_t *title)
virtual TGo4ConditionPainterCreatePainter ()
 Factory method to generate the subclass implentation for painter. More...

virtual void SetPainter (TGo4ConditionPainter *painter)
 Replace default painter of this condition by external one. More...

void SetValues (Double_t *x, Double_t *y, Int_t len)
 Delete old cut and create a new cut with X,Y values. More...

void SetValues (TCutG *newcut)
 Delete old cut and create new one by cloning newcut. More...

Bool_t Test (Double_t x, Double_t y)
 Test if X,Y are inside. More...

virtual Double_t GetXLow ()
 minimum extension of polygon in x axis. More...

virtual Double_t GetXUp ()
 maximum extension of polygon in x axis. More...

virtual Double_t GetYLow ()
 minimum extension of polygon in y axis. More...

virtual Double_t GetYUp ()
 maximum extension of polygon in y axis. More...

TCutG * GetCut (Bool_t changeowner)
 Used to return the cut pointer of a TGo4PolyCond. More...

void PrintCondition (Bool_t points)
 Printout values. More...

Bool_t UpdateFrom (TGo4Condition *cond, Bool_t counts)
 Copy values from cond to this. More...

virtual Double_t GetIntegral (TH1 *histo, Option_t *opt="")
 Calculate value for histogram inside condition limits. More...

virtual Double_t GetMean (TH1 *histo, Int_t axis=1)
 Calculate value for histogram inside condition limits. More...

virtual Double_t GetRMS (TH1 *histo, Int_t axis=1)
 Calculate value for histogram inside condition limits. More...

virtual Double_t GetXMax (TH1 *histo)
 Calculate value for histogram inside condition limits. More...

virtual Double_t GetYMax (TH1 *histo)
 Calculate value for histogram inside condition limits. More...

virtual Double_t GetCMax (TH1 *histo)
 Calculate value for histogram inside condition limits. More...

virtual Bool_t IsPolygonType ()

Static Public Methods

void CleanupSpecials ()
 Remove all references to any TCutGs from ROOT list of specials. More...


Private Methods

TCutG * CloneCut (TGo4PolyCond *source)
 Returns pointer to a cloned cut from source. More...

TH2 * CreateCutHistogram (TH1 *source)
 Create clone of source histogram that only has contents for bins inside the current TCutG. More...


Private Attributes

Double_t fXmin
 Minimum X coordinate. More...

Double_t fXmax
 Maximum X coordinate. More...

Double_t fYmin
 Minimum Y coordinate. More...

Double_t fYmax
 Maximum Y coordinate. More...

Int_t fiPoints
 Number of points. More...

TCutG * cut
 Cut pointer. More...


Constructor & Destructor Documentation

TGo4PolyCond::TGo4PolyCond  
 

Definition at line 43 of file TGo4PolyCond.cxx.

References cut, fiPoints, and TGo4Condition::SetDimension().

TGo4PolyCond::~TGo4PolyCond   [virtual]
 

Definition at line 51 of file TGo4PolyCond.cxx.

References cut.

TGo4PolyCond::TGo4PolyCond const Text_t *    name
 

Definition at line 35 of file TGo4PolyCond.cxx.

References cut, fiPoints, and TGo4Condition::SetDimension().

TGo4PolyCond::TGo4PolyCond const Text_t *    name,
const Text_t *    title
 

Definition at line 27 of file TGo4PolyCond.cxx.

References cut, fiPoints, and TGo4Condition::SetDimension().


Member Function Documentation

TGo4ConditionPainter * TGo4PolyCond::CreatePainter   [virtual]
 

Factory method to generate the subclass implentation for painter.

Reimplemented from TGo4Condition.

Definition at line 300 of file TGo4PolyCond.cxx.

References TGo4ConditionPainter::SetCondition().

void TGo4PolyCond::SetPainter TGo4ConditionPainter   painter [virtual]
 

Replace default painter of this condition by external one.

if different views of this condition shall exist for different TPads, the painter (i.e. view) can be exchanged before pad is updated.

Reimplemented from TGo4Condition.

Definition at line 281 of file TGo4PolyCond.cxx.

References TGo4Condition::fxPainter, TGo4ConditionPainter::SetCondition(), and TGo4Log::Warn().

void TGo4PolyCond::SetValues Double_t *    x,
Double_t *    y,
Int_t    len
[virtual]
 

Delete old cut and create a new cut with X,Y values.

Reimplemented from TGo4Condition.

Definition at line 135 of file TGo4PolyCond.cxx.

References cut, and TGo4Condition::fxCutHis.

Referenced by TGo4WindowEditSlots::CreateNewCondition(), TGo4AnalysisObjectManager::MakePolyCond(), TGo4PreviewPanelSlots::ScanCutG(), TGo4WindowEditSlots::SetNewTCutG(), TXXXProc::TXXXProc(), TXXXUnpackProc::TXXXUnpackProc(), TYYYUnpackProc::TYYYUnpackProc(), and TGo4PolyCondView::UpdateCondition().

void TGo4PolyCond::SetValues TCutG *    newcut [virtual]
 

Delete old cut and create new one by cloning newcut.

Reimplemented from TGo4Condition.

Definition at line 119 of file TGo4PolyCond.cxx.

References cut, and TGo4Condition::fxCutHis.

Bool_t TGo4PolyCond::Test Double_t    x,
Double_t    y
[virtual]
 

Test if X,Y are inside.

Reimplemented from TGo4Condition.

Definition at line 144 of file TGo4PolyCond.cxx.

References cut, TGo4Condition::FixedResult(), TGo4Condition::IncCounts(), TGo4Condition::IncTrueCounts(), TGo4Condition::IsEnabled(), TGo4Condition::IsFalse(), and TGo4Condition::IsTrue().

Referenced by TXXXProc::Event(), and TXXXUnpackProc::XXXUnpack().

Double_t TGo4PolyCond::GetXLow   [virtual]
 

minimum extension of polygon in x axis.

Reimplemented from TGo4Condition.

Definition at line 56 of file TGo4PolyCond.cxx.

References cut, and n.

Double_t TGo4PolyCond::GetXUp   [virtual]
 

maximum extension of polygon in x axis.

Reimplemented from TGo4Condition.

Definition at line 64 of file TGo4PolyCond.cxx.

References cut, and n.

Double_t TGo4PolyCond::GetYLow   [virtual]
 

minimum extension of polygon in y axis.

Reimplemented from TGo4Condition.

Definition at line 72 of file TGo4PolyCond.cxx.

References cut, and n.

Double_t TGo4PolyCond::GetYUp   [virtual]
 

maximum extension of polygon in y axis.

Reimplemented from TGo4Condition.

Definition at line 80 of file TGo4PolyCond.cxx.

References cut, and n.

TCutG * TGo4PolyCond::GetCut Bool_t    changeowner [virtual]
 

Used to return the cut pointer of a TGo4PolyCond.

In source, pointer is set to 0, when changeowner is true. Thus source object can be deleted without deleting the cut which is now owned by the caller. When changeowner is false, the pointer can only be used to clone a new cut. The cut must not be deleted!

Reimplemented from TGo4Condition.

Definition at line 95 of file TGo4PolyCond.cxx.

References cut, and TGo4Condition::fxCutHis.

Referenced by CloneCut(), TGo4ConditionStatus::ConditionSize(), TGo4PolyCondView::IsCutChanged(), TGo4PolyCondPainter::PaintCondition(), and TGo4ConditionPainter::PaintLabel().

void TGo4PolyCond::PrintCondition Bool_t    points [virtual]
 

Printout values.

If points is true, printout polygon points.

Reimplemented from TGo4Condition.

Definition at line 156 of file TGo4PolyCond.cxx.

References cut, and TGo4Condition::PrintCondition().

Referenced by TGo4CondArray::PrintCondition(), TXXXUnpackProc::TXXXUnpackProc(), TYYYUnpackProc::TYYYUnpackProc(), TXXXUnpackProc::~TXXXUnpackProc(), and TYYYUnpackProc::~TYYYUnpackProc().

Bool_t TGo4PolyCond::UpdateFrom TGo4Condition   cond,
Bool_t    counts
[virtual]
 

Copy values from cond to this.

Get a clone cut from cond by CloneCut as new cut. If counts is true, copy counters too.

Reimplemented from TGo4Condition.

Definition at line 174 of file TGo4PolyCond.cxx.

References CleanupSpecials(), CloneCut(), cut, TGo4Condition::fxCutHis, and TGo4Condition::UpdateFrom().

Double_t TGo4PolyCond::GetIntegral TH1 *    histo,
Option_t *    opt = ""
[virtual]
 

Calculate value for histogram inside condition limits.

Reimplemented from TGo4Condition.

Definition at line 203 of file TGo4PolyCond.cxx.

References CreateCutHistogram(), cut, and TGo4Condition::fxCutHis.

Double_t TGo4PolyCond::GetMean TH1 *    histo,
Int_t    axis = 1
[virtual]
 

Calculate value for histogram inside condition limits.

Reimplemented from TGo4Condition.

Definition at line 222 of file TGo4PolyCond.cxx.

References CreateCutHistogram(), and TGo4Condition::fxCutHis.

Double_t TGo4PolyCond::GetRMS TH1 *    histo,
Int_t    axis = 1
[virtual]
 

Calculate value for histogram inside condition limits.

Reimplemented from TGo4Condition.

Definition at line 230 of file TGo4PolyCond.cxx.

References CreateCutHistogram(), and TGo4Condition::fxCutHis.

Double_t TGo4PolyCond::GetXMax TH1 *    histo [virtual]
 

Calculate value for histogram inside condition limits.

Reimplemented from TGo4Condition.

Definition at line 238 of file TGo4PolyCond.cxx.

References CreateCutHistogram(), and TGo4Condition::fxCutHis.

Double_t TGo4PolyCond::GetYMax TH1 *    histo [virtual]
 

Calculate value for histogram inside condition limits.

Reimplemented from TGo4Condition.

Definition at line 255 of file TGo4PolyCond.cxx.

References CreateCutHistogram(), and TGo4Condition::fxCutHis.

Double_t TGo4PolyCond::GetCMax TH1 *    histo [virtual]
 

Calculate value for histogram inside condition limits.

Reimplemented from TGo4Condition.

Definition at line 272 of file TGo4PolyCond.cxx.

References CreateCutHistogram(), and TGo4Condition::fxCutHis.

Bool_t TGo4PolyCond::IsPolygonType   [virtual]
 

Reimplemented from TGo4Condition.

Definition at line 89 of file TGo4PolyCond.cxx.

void TGo4PolyCond::CleanupSpecials   [static]
 

Remove all references to any TCutGs from ROOT list of specials.

To be used after loading condition from file, updating contition, or setting of cut.

Definition at line 341 of file TGo4PolyCond.cxx.

Referenced by TGo4WindowEditSlots::ClearConditions(), TGo4AnalysisObjectManager::CreateNamesList(), TGo4WindowEditSlots::DrawConditions(), TGo4WindowEditSlots::EnterEvent(), TGo4PreviewPanelSlots::LoadMarkerSetup(), TGo4AnalysisObjectManager::LoadObjects(), TGo4AnalysisObjectManager::SetAnalysisCondition(), TGo4PolyCondView::UpdateCondition(), and UpdateFrom().

TCutG * TGo4PolyCond::CloneCut TGo4PolyCond *    source [private]
 

Returns pointer to a cloned cut from source.

Name is set to callers name. Used internally by UpdateFrom.

Definition at line 113 of file TGo4PolyCond.cxx.

References GetCut().

Referenced by UpdateFrom().

TH2 * TGo4PolyCond::CreateCutHistogram TH1 *    source [private]
 

Create clone of source histogram that only has contents for bins inside the current TCutG.

For calculation of statistical values.

Definition at line 307 of file TGo4PolyCond.cxx.

References cut, and i.

Referenced by GetCMax(), GetIntegral(), GetMean(), GetRMS(), GetXMax(), and GetYMax().


Member Data Documentation

Double_t TGo4PolyCond::fXmin [private]
 

Minimum X coordinate.

Definition at line 130 of file TGo4PolyCond.h.

Double_t TGo4PolyCond::fXmax [private]
 

Maximum X coordinate.

Definition at line 134 of file TGo4PolyCond.h.

Double_t TGo4PolyCond::fYmin [private]
 

Minimum Y coordinate.

Definition at line 138 of file TGo4PolyCond.h.

Double_t TGo4PolyCond::fYmax [private]
 

Maximum Y coordinate.

Definition at line 142 of file TGo4PolyCond.h.

Int_t TGo4PolyCond::fiPoints [private]
 

Number of points.

Definition at line 146 of file TGo4PolyCond.h.

Referenced by TGo4PolyCond().

TCutG* TGo4PolyCond::cut [private]
 

Cut pointer.

Definition at line 150 of file TGo4PolyCond.h.

Referenced by CreateCutHistogram(), GetCut(), GetIntegral(), GetXLow(), GetXUp(), GetYLow(), GetYUp(), PrintCondition(), SetValues(), Test(), TGo4PolyCond(), UpdateFrom(), and ~TGo4PolyCond().


The documentation for this class was generated from the following files:
Generated on Tue Nov 8 10:56:49 2005 for Go4-v2.10-5 by doxygen1.2.15