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

TGo4DynamicEntry Class Reference

ABC for all entries that can be kept in a dynamic list. More...

#include <TGo4DynamicEntry.h>

Inheritance diagram for TGo4DynamicEntry:

TGo4DynamicList TGo4HistogramEntry TGo4TreeHistogramEntry List of all members.

Public Methods

 TGo4DynamicEntry ()
 default ctor for streamer. More...

 TGo4DynamicEntry (const Text_t *name)
virtual ~TGo4DynamicEntry ()
virtual Int_t Process ()=0
 Process the dynamic entry. More...

void EnableProcessing (Bool_t on=kTRUE)
 Switch the autoprocessing state of this entry. More...

virtual TGo4DynamicEntryStatusCreateStatus ()=0
 Create a status object containing information such as the object names. More...

virtual void SetStatus (TGo4DynamicEntryStatus *state)
 Set this dynamic entry to the values of status object state. More...

virtual void Reset ()
 Resets this entry to an initial status. More...

virtual void InitPointers ()
 Initialize the pointers to external objects. More...

void SetConditionName (const Text_t *name)
 Set name of the external condition to be referenced. More...

virtual void CleanupCondition (TGo4Condition *con)
 If condition con matches the internal condition, the reference to internal condition will be reset to 0. More...

virtual void CleanupEvent (TGo4EventElement *ev)
 If event ev matches one internal event, the reference to event will be reset to 0. More...

virtual void CleanupHistogram (TH1 *his)
 If histogram his matches the internal histogram, the reference to internal histogram will be reset to 0. More...

Bool_t TestCondition ()
 Test if condition for this entry is true. More...

void SetConVarName (UInt_t ix, const Text_t *name)
 Set Name of the data value (eventclass member) that is to be tested by condition for axis number ix. More...

void SetConEventName (UInt_t ix, const Text_t *name)
 Set Name of the eventstructure object that is to be tested by the condition for axis number ix. More...


Static Public Attributes

const Text_t fgcNOCONDITION [] = "No Condition"
 Text to indicate that no condition is used. More...

const Text_t fgcNODATA [] = "No Data"
 Text to indicate that no condition is used. More...

const Text_t fgcNOEVENT [] = "No Event"
 Text to indicate that no condition is used. More...

const UInt_t fguMAXCONDIMENSION = __MAXCONDIM__
 maximum dimension for condition variable array. More...


Protected Methods

virtual void UpdateStatus (TGo4DynamicEntryStatus *state)
 Update the status object containing information such as the object names. More...

TDataMember * FindDataMember (TClass *eventclass, const Text_t *memname, Long_t *totaloffset)
 Find out address totaloffset of datamember memname relative to "this" pointer of eventclass object. More...

Int_t Membersize (const Text_t *name)
 find out size of type "name" on runtime for all supported types. More...


Protected Attributes

Bool_t fbProcessEntry
 True if object shall be processed by main event loop automatically. More...

Bool_t fbPointerInitDone
 True if pointers to external objects have already been initialized. More...


Private Attributes

TGo4ConditionfxCondition
 Condition to be checked on processing this entry. More...

TString fxConditionName
 Name of the condition to be applied for this entry. More...

TString fxConVarName [__MAXCONDIM__]
 Name of the eventstructure datamembers that shall be tested with the condition. More...

TString fxConEventName [__MAXCONDIM__]
 Array of names of the events which contain the data members to be tested with the x,y coordinates of the condition. More...

TGo4EventElementfxConEvent [__MAXCONDIM__]
 Array of pointers to the event structure that contains the data for the condition test. More...

Float_t * fxConDataFloat [__MAXCONDIM__]
 Array of pointers to the data that is tested against condition. More...

Double_t * fxConDataDouble [__MAXCONDIM__]
 Array of pointers to the data that is tested against condition. More...

Int_t * fxConDataInt [__MAXCONDIM__]
 Array of pointers to the data that is tested against condition. More...

Short_t * fxConDataShort [__MAXCONDIM__]
 Array of pointers to the data that is tested against condition. More...

Char_t * fxConDataChar [__MAXCONDIM__]
 Array of pointers to the data that is tested against condition. More...

Long_t * fxConDataLong [__MAXCONDIM__]
 Array of pointers to the data that is tested against condition. More...

Bool_t * fxConDataBool [__MAXCONDIM__]
 Array of pointers to the data that is tested against condition. More...

UInt_t * fxConDataUInt [__MAXCONDIM__]
 Array of pointers to the data that is tested against condition. More...

UShort_t * fxConDataUShort [__MAXCONDIM__]
 Array of pointers to the data that is tested against condition. More...

UChar_t * fxConDataUChar [__MAXCONDIM__]
 Array of pointers to the data that is tested against condition. More...

ULong_t * fxConDataULong [__MAXCONDIM__]
 Array of pointers to the data that is tested against condition. More...


Detailed Description

ABC for all entries that can be kept in a dynamic list.

The Dynamic list itself is a dynamic entry, too; thus the analysis can handle a dynamic list containing dynamic sub-lists of histograms. @interface

Author:
J. Adamczewski
Since:
1/2001

Definition at line 39 of file TGo4DynamicEntry.h.


Constructor & Destructor Documentation

TGo4DynamicEntry::TGo4DynamicEntry  
 

default ctor for streamer.

Definition at line 35 of file TGo4DynamicEntry.cxx.

References TRACE.

TGo4DynamicEntry::TGo4DynamicEntry const Text_t *    name
 

Definition at line 51 of file TGo4DynamicEntry.cxx.

References fgcNOCONDITION, fgcNODATA, fgcNOEVENT, fguMAXCONDIMENSION, fxConditionName, Reset(), SetConEventName(), SetConVarName(), and TRACE.

TGo4DynamicEntry::~TGo4DynamicEntry   [virtual]
 

Definition at line 66 of file TGo4DynamicEntry.cxx.

References TRACE.


Member Function Documentation

virtual Int_t TGo4DynamicEntry::Process   [pure virtual]
 

Process the dynamic entry.

Implemented in TGo4DynamicList, TGo4HistogramEntry, and TGo4TreeHistogramEntry.

Referenced by TGo4DynamicList::Process().

void TGo4DynamicEntry::EnableProcessing Bool_t    on = kTRUE [inline]
 

Switch the autoprocessing state of this entry.

Definition at line 65 of file TGo4DynamicEntry.h.

References fbProcessEntry.

Referenced by TGo4DynamicListException::Handle(), SetStatus(), and TGo4TreeHistogramEntry::TGo4TreeHistogramEntry().

virtual TGo4DynamicEntryStatus* TGo4DynamicEntry::CreateStatus   [pure virtual]
 

Create a status object containing information such as the object names.

Can be sent to the Display to show the existing objects and their relations. Memento mechanism is _not_ provided here, since we would not change the object names afterwards.

Implemented in TGo4DynamicList, TGo4HistogramEntry, and TGo4TreeHistogramEntry.

Referenced by TGo4EditDynEntrySlots::AddObject(), TGo4DynamicList::CreateEntryStatus(), and TGo4DynamicList::UpdateStatus().

void TGo4DynamicEntry::SetStatus TGo4DynamicEntryStatus   state [virtual]
 

Set this dynamic entry to the values of status object state.

Reimplemented in TGo4DynamicList, TGo4HistogramEntry, and TGo4TreeHistogramEntry.

Definition at line 359 of file TGo4DynamicEntry.cxx.

References TGo4DynamicEntryStatus::AutoProcessIsEnabled(), EnableProcessing(), fguMAXCONDIMENSION, TGo4DynamicEntryStatus::GetConditionName(), TGo4DynamicEntryStatus::GetConEventName(), TGo4DynamicEntryStatus::GetConVarName(), i, Reset(), SetConditionName(), SetConEventName(), SetConVarName(), and TRACE.

Referenced by TGo4DynamicList::SetEntryStatus(), TGo4TreeHistogramEntry::SetStatus(), TGo4HistogramEntry::SetStatus(), and TGo4DynamicList::SetStatus().

void TGo4DynamicEntry::Reset   [virtual]
 

Resets this entry to an initial status.

Reimplemented in TGo4DynamicList, TGo4HistogramEntry, and TGo4TreeHistogramEntry.

Definition at line 102 of file TGo4DynamicEntry.cxx.

References fbPointerInitDone, fguMAXCONDIMENSION, fxConDataBool, fxConDataChar, fxConDataDouble, fxConDataFloat, fxConDataInt, fxConDataLong, fxConDataShort, fxConDataUChar, fxConDataUInt, fxConDataULong, fxConDataUShort, fxCondition, fxConEvent, and TRACE.

Referenced by CleanupCondition(), CleanupEvent(), TGo4AnalysisObjectManager::ClearObjects(), InitPointers(), TGo4TreeHistogramEntry::Reset(), TGo4HistogramEntry::Reset(), TGo4DynamicList::Reset(), SetStatus(), and TGo4DynamicEntry().

void TGo4DynamicEntry::InitPointers   [virtual]
 

Initialize the pointers to external objects.

The external objects (e.g. condition, histogram, data) will be searched by name in the Go4 folders.

Reimplemented in TGo4HistogramEntry.

Definition at line 125 of file TGo4DynamicEntry.cxx.

References fbPointerInitDone, fgcNOCONDITION, fgcNODATA, fgcNOEVENT, fguMAXCONDIMENSION, FindDataMember(), fxConDataBool, fxConDataChar, fxConDataDouble, fxConDataFloat, fxConDataInt, fxConDataLong, fxConDataShort, fxConDataUChar, fxConDataUInt, fxConDataULong, fxConDataUShort, fxCondition, fxConditionName, fxConEvent, fxConEventName, fxConVarName, TGo4Analysis::GetAnalysisCondition(), TGo4Analysis::GetEventStructure(), TGo4Analysis::Instance(), Reset(), and TRACE.

Referenced by TGo4HistogramEntry::InitPointers(), and TestCondition().

void TGo4DynamicEntry::SetConditionName const Text_t *    name
 

Set name of the external condition to be referenced.

Definition at line 354 of file TGo4DynamicEntry.cxx.

References fxConditionName.

Referenced by SetStatus().

void TGo4DynamicEntry::CleanupCondition TGo4Condition   con [virtual]
 

If condition con matches the internal condition, the reference to internal condition will be reset to 0.

This is used when external condition is deleted to avoid dead pointers.

Reimplemented in TGo4DynamicList.

Definition at line 95 of file TGo4DynamicEntry.cxx.

References fxCondition, Reset(), and TRACE.

Referenced by TGo4DynamicList::CleanupCondition().

void TGo4DynamicEntry::CleanupEvent TGo4EventElement   ev [virtual]
 

If event ev matches one internal event, the reference to event will be reset to 0.

This is used when external event is deleted to avoid dead pointers. May be overloaded if subclasses also keep pointers to event structures.

Reimplemented in TGo4DynamicList, and TGo4HistogramEntry.

Definition at line 374 of file TGo4DynamicEntry.cxx.

References fguMAXCONDIMENSION, fxConEvent, Reset(), and TRACE.

Referenced by TGo4HistogramEntry::CleanupEvent(), and TGo4DynamicList::CleanupEvent().

void TGo4DynamicEntry::CleanupHistogram TH1 *    his [virtual]
 

If histogram his matches the internal histogram, the reference to internal histogram will be reset to 0.

This is used when external histogram is deleted to avoid dead pointers. Dummy implementation here!

Reimplemented in TGo4DynamicList, and TGo4HistogramEntry.

Definition at line 387 of file TGo4DynamicEntry.cxx.

Referenced by TGo4HistogramEntry::CleanupHistogram(), and TGo4DynamicList::CleanupHistogram().

Bool_t TGo4DynamicEntry::TestCondition  
 

Test if condition for this entry is true.

Definition at line 262 of file TGo4DynamicEntry.cxx.

References fbPointerInitDone, fguMAXCONDIMENSION, fxConDataBool, fxConDataChar, fxConDataDouble, fxConDataFloat, fxConDataInt, fxConDataLong, fxConDataShort, fxConDataUChar, fxConDataUInt, fxConDataULong, fxConDataUShort, fxCondition, TGo4Condition::GetLast(), InitPointers(), TGo4Condition::Test(), and TRACE.

Referenced by TGo4HistogramEntry::Process().

void TGo4DynamicEntry::SetConVarName UInt_t    ix,
const Text_t *    name
 

Set Name of the data value (eventclass member) that is to be tested by condition for axis number ix.

ix is 0 for x-axis, 1 for y-axis, etc.

Definition at line 342 of file TGo4DynamicEntry.cxx.

References fguMAXCONDIMENSION, fxConVarName, and TRACE.

Referenced by SetStatus(), and TGo4DynamicEntry().

void TGo4DynamicEntry::SetConEventName UInt_t    ix,
const Text_t *    name
 

Set Name of the eventstructure object that is to be tested by the condition for axis number ix.

ix is 0 for x-axis, 1 for y-axis, etc.

Definition at line 348 of file TGo4DynamicEntry.cxx.

References fguMAXCONDIMENSION, fxConEventName, and TRACE.

Referenced by SetStatus(), and TGo4DynamicEntry().

void TGo4DynamicEntry::UpdateStatus TGo4DynamicEntryStatus   state [protected, virtual]
 

Update the status object containing information such as the object names.

Can be sent to the Display to show the existing objects and their relations. Memento mechanism is _not_ provided here, since we would not change the object names afterwards.

Reimplemented in TGo4DynamicList, TGo4HistogramEntry, and TGo4TreeHistogramEntry.

Definition at line 73 of file TGo4DynamicEntry.cxx.

References fbPointerInitDone, fbProcessEntry, fxCondition, TGo4DynamicEntryStatus::fxConditionClass, fxConditionName, TGo4DynamicEntryStatus::fxConditionName, fxConEventName, fxConVarName, TGo4DynamicEntryStatus::SetCondition(), TGo4DynamicEntryStatus::SetConEventNames(), TGo4DynamicEntryStatus::SetConVarNames(), TGo4DynamicEntryStatus::SetFlags(), and TRACE.

Referenced by TGo4TreeHistogramEntry::UpdateStatus(), TGo4HistogramEntry::UpdateStatus(), and TGo4DynamicList::UpdateStatus().

TDataMember * TGo4DynamicEntry::FindDataMember TClass *    eventclass,
const Text_t *    memname,
Long_t *    totaloffset
[protected]
 

Find out address totaloffset of datamember memname relative to "this" pointer of eventclass object.

Datamember object is returned. This method is able to treat inherited members. Later on, also aggregates?

Definition at line 393 of file TGo4DynamicEntry.cxx.

References Membersize(), and TRACE.

Referenced by TGo4HistogramEntry::InitPointers(), and InitPointers().

Int_t TGo4DynamicEntry::Membersize const Text_t *    name [protected]
 

find out size of type "name" on runtime for all supported types.

Definition at line 493 of file TGo4DynamicEntry.cxx.

Referenced by FindDataMember().


Member Data Documentation

const Text_t TGo4DynamicEntry::fgcNOCONDITION = "No Condition" [static]
 

Text to indicate that no condition is used.

Definition at line 30 of file TGo4DynamicEntry.cxx.

Referenced by TGo4HistogramEntry::InitPointers(), InitPointers(), TGo4HistogramEntryStatus::ResetNames(), TGo4DynamicEntryStatus::ResetNames(), TGo4EditDynEntryStatus::SetConditionEnabled(), TGo4DynamicEntry(), and TGo4HistogramEntry::TGo4HistogramEntry().

const Text_t TGo4DynamicEntry::fgcNODATA = "No Data" [static]
 

Text to indicate that no condition is used.

Definition at line 31 of file TGo4DynamicEntry.cxx.

Referenced by TGo4AnalysisObjectManager::AddDynamicHistogram(), TGo4HistogramEntry::InitPointers(), InitPointers(), TGo4HistogramEntryStatus::ResetNames(), TGo4DynamicEntryStatus::ResetNames(), TGo4EditDynEntryStatus::SetConditionYEnabled(), TGo4EditDynEntryStatus::SetHisYEnabled(), TGo4EditDynEntryStatus::SetHisZEnabled(), TGo4DynamicEntry(), and TGo4HistogramEntry::TGo4HistogramEntry().

const Text_t TGo4DynamicEntry::fgcNOEVENT = "No Event" [static]
 

Text to indicate that no condition is used.

Definition at line 32 of file TGo4DynamicEntry.cxx.

Referenced by TGo4AnalysisObjectManager::AddDynamicHistogram(), TGo4HistogramEntry::InitPointers(), InitPointers(), TGo4HistogramEntryStatus::ResetNames(), TGo4DynamicEntryStatus::ResetNames(), TGo4EditDynEntryStatus::SetConditionYEnabled(), TGo4EditDynEntryStatus::SetHisYEnabled(), TGo4EditDynEntryStatus::SetHisZEnabled(), TGo4DynamicEntry(), and TGo4HistogramEntry::TGo4HistogramEntry().

const UInt_t TGo4DynamicEntry::fguMAXCONDIMENSION = __MAXCONDIM__ [static]
 

maximum dimension for condition variable array.

Definition at line 33 of file TGo4DynamicEntry.cxx.

Referenced by TGo4AnalysisObjectManager::AddDynamicHistogram(), CleanupEvent(), TGo4DynamicEntryStatus::GetConEventName(), TGo4DynamicEntryStatus::GetConVarName(), InitPointers(), Reset(), TGo4DynamicEntryStatus::ResetNames(), TGo4DynamicEntryStatus::SetConEventName(), SetConEventName(), TGo4DynamicEntryStatus::SetConEventNames(), TGo4DynamicEntryStatus::SetConVarName(), SetConVarName(), TGo4DynamicEntryStatus::SetConVarNames(), SetStatus(), TestCondition(), and TGo4DynamicEntry().

Bool_t TGo4DynamicEntry::fbProcessEntry [protected]
 

True if object shall be processed by main event loop automatically.

For example, histogram autofill from event index values.

Definition at line 137 of file TGo4DynamicEntry.h.

Referenced by EnableProcessing(), TGo4TreeHistogramEntry::Process(), TGo4HistogramEntry::Process(), and UpdateStatus().

Bool_t TGo4DynamicEntry::fbPointerInitDone [protected]
 

True if pointers to external objects have already been initialized.

Flag is set by InitPointers() and reset by Reset().

Definition at line 141 of file TGo4DynamicEntry.h.

Referenced by TGo4HistogramEntry::InitPointers(), InitPointers(), TGo4HistogramEntry::Process(), Reset(), TestCondition(), and UpdateStatus().

TGo4Condition* TGo4DynamicEntry::fxCondition [private]
 

Condition to be checked on processing this entry.

Definition at line 146 of file TGo4DynamicEntry.h.

Referenced by CleanupCondition(), InitPointers(), Reset(), TestCondition(), and UpdateStatus().

TString TGo4DynamicEntry::fxConditionName [private]
 

Name of the condition to be applied for this entry.

Definition at line 149 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), SetConditionName(), TGo4DynamicEntry(), and UpdateStatus().

TString TGo4DynamicEntry::fxConVarName[__MAXCONDIM__] [private]
 

Name of the eventstructure datamembers that shall be tested with the condition.

Definition at line 153 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), SetConVarName(), and UpdateStatus().

TString TGo4DynamicEntry::fxConEventName[__MAXCONDIM__] [private]
 

Array of names of the events which contain the data members to be tested with the x,y coordinates of the condition.

Definition at line 158 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), SetConEventName(), and UpdateStatus().

TGo4EventElement* TGo4DynamicEntry::fxConEvent[__MAXCONDIM__] [private]
 

Array of pointers to the event structure that contains the data for the condition test.

Definition at line 162 of file TGo4DynamicEntry.h.

Referenced by CleanupEvent(), InitPointers(), and Reset().

Float_t* TGo4DynamicEntry::fxConDataFloat[__MAXCONDIM__] [private]
 

Array of pointers to the data that is tested against condition.

Used if data is Float_t

Definition at line 166 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), Reset(), and TestCondition().

Double_t* TGo4DynamicEntry::fxConDataDouble[__MAXCONDIM__] [private]
 

Array of pointers to the data that is tested against condition.

Used if data is Double_t

Definition at line 170 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), Reset(), and TestCondition().

Int_t* TGo4DynamicEntry::fxConDataInt[__MAXCONDIM__] [private]
 

Array of pointers to the data that is tested against condition.

Used if data is Int_t

Definition at line 174 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), Reset(), and TestCondition().

Short_t* TGo4DynamicEntry::fxConDataShort[__MAXCONDIM__] [private]
 

Array of pointers to the data that is tested against condition.

Used if data is Short_t

Definition at line 178 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), Reset(), and TestCondition().

Char_t* TGo4DynamicEntry::fxConDataChar[__MAXCONDIM__] [private]
 

Array of pointers to the data that is tested against condition.

Used if data is Char_t

Definition at line 182 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), Reset(), and TestCondition().

Long_t* TGo4DynamicEntry::fxConDataLong[__MAXCONDIM__] [private]
 

Array of pointers to the data that is tested against condition.

Used if data is Long_t

Definition at line 186 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), Reset(), and TestCondition().

Bool_t* TGo4DynamicEntry::fxConDataBool[__MAXCONDIM__] [private]
 

Array of pointers to the data that is tested against condition.

Used if data is Bool_t

Definition at line 190 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), Reset(), and TestCondition().

UInt_t* TGo4DynamicEntry::fxConDataUInt[__MAXCONDIM__] [private]
 

Array of pointers to the data that is tested against condition.

Used if data is UInt_t

Definition at line 194 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), Reset(), and TestCondition().

UShort_t* TGo4DynamicEntry::fxConDataUShort[__MAXCONDIM__] [private]
 

Array of pointers to the data that is tested against condition.

Used if data is UShort_t

Definition at line 198 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), Reset(), and TestCondition().

UChar_t* TGo4DynamicEntry::fxConDataUChar[__MAXCONDIM__] [private]
 

Array of pointers to the data that is tested against condition.

Used if data is UChar_t

Definition at line 202 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), Reset(), and TestCondition().

ULong_t* TGo4DynamicEntry::fxConDataULong[__MAXCONDIM__] [private]
 

Array of pointers to the data that is tested against condition.

Used if data is Long_t

Definition at line 206 of file TGo4DynamicEntry.h.

Referenced by InitPointers(), Reset(), and TestCondition().


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