(UNKNOWN PRODUCT) » ANALYZE » TUsrEvent

class TUsrEvent: public TObject

__________________________________________________[C++ CLASS IMPLEMENTATION]

 Name:           TUsrEvent.cxx
 Purpose:        Implement class methods for user's analysis
 Description:    Base class for user-defined events
 Keywords:
 Author:         R. Lutter
 Mailto:         <a href=mailto:rudi.lutter@physik.uni-muenchen.de>R. Lutter</a>
 Revision:       $Id: TUsrEvent.cxx,v 1.11 2011/09/16 12:12:32 Marabou Exp $
 Date:

Function Members (Methods)

public:
TUsrEvent()
virtual~TUsrEvent()
voidTObject::AbstractMethod(const char* method) const
voidAddHBX(TUsrHBX* HBX, Int_t SevtSerial = -1)
voidAddSubevent(TObject* Subevent, Int_t SevtSerial = -1)
virtual voidTObject::AppendPad(Option_t* option = "")
virtual voidTObject::Browse(TBrowser* b)
Int_tCalcTimeDiff(TUsrEvent* Event) const
static TClass*Class()
virtual const char*TObject::ClassName() const
virtual voidTObject::Clear(Option_t* = "")
virtual TObject*TObject::Clone(const char* newname = "") const
virtual Int_tTObject::Compare(const TObject* obj) const
virtual voidTObject::Copy(TObject& object) const
virtual voidTObject::Delete(Option_t* option = "")MENU
virtual Int_tTObject::DistancetoPrimitive(Int_t px, Int_t py)
virtual voidTObject::Draw(Option_t* option = "")
virtual voidTObject::DrawClass() constMENU
virtual TObject*TObject::DrawClone(Option_t* option = "") constMENU
virtual voidTObject::Dump() constMENU
virtual voidTObject::Error(const char* method, const char* msgfmt) const
virtual voidTObject::Execute(const char* method, const char* params, Int_t* error = 0)
virtual voidTObject::Execute(TMethod* method, TObjArray* params, Int_t* error = 0)
virtual voidTObject::ExecuteEvent(Int_t event, Int_t px, Int_t py)
virtual voidTObject::Fatal(const char* method, const char* msgfmt) const
Bool_tFillEventFromHB(TArrayI& LofIndices, Bool_t FillHisto = kTRUE, Int_t Didx = TUsrHit::kHitEnergy, Int_t InitValue = 0)
Int_tFillSevtFromHB(TUsrHBX* HBX, Int_t Hidx, Bool_t FillHisto = kTRUE, Int_t Didx = TUsrHit::kHitEnergy)
virtual TObject*TObject::FindObject(const char* name) const
virtual TObject*TObject::FindObject(const TObject* obj) const
Int_tGetClockNsecs() const
Int_tGetClockSecs() const
virtual Option_t*TObject::GetDrawOption() const
static Long_tTObject::GetDtorOnly()
TUsrHBX*GetHBX(Int_t SevtSerial)
virtual const char*TObject::GetIconName() const
TObjArray*GetLofSubevents()
virtual const char*TObject::GetName() const
Int_tGetNofEvents() const
Int_tGetNofSubevents() const
virtual char*TObject::GetObjectInfo(Int_t px, Int_t py) const
static Bool_tTObject::GetObjectStat()
virtual Option_t*TObject::GetOption() const
Int_tGetScaleDown() const
TObject*GetSubevent(Int_t SevtSerial)
Int_tGetTimeRS() const
Int_tGetTimeStamp() const
virtual const char*TObject::GetTitle() const
TTree*GetTreeIn() const
TTree*GetTreeOut() const
virtual UInt_tTObject::GetUniqueID() const
virtual Bool_tTObject::HandleTimer(TTimer* timer)
virtual ULong_tTObject::Hash() const
voidHelp()
virtual voidTObject::Info(const char* method, const char* msgfmt) const
virtual Bool_tTObject::InheritsFrom(const char* classname) const
virtual Bool_tTObject::InheritsFrom(const TClass* cl) const
virtual voidTObject::Inspect() constMENU
voidTObject::InvertBit(UInt_t f)
virtual TClass*IsA() const
virtual Bool_tTObject::IsEqual(const TObject* obj) const
Bool_tIsFakeMode() const
virtual Bool_tTObject::IsFolder() const
Bool_tIsModScaleDown() const
Bool_tTObject::IsOnHeap() const
Bool_tIsReplayMode() const
virtual Bool_tTObject::IsSortable() const
Bool_tTObject::IsZombie() const
virtual voidTObject::ls(Option_t* option = "") const
voidTObject::MayNotUse(const char* method) const
const UShort_t*NextSubevent(MBSDataIO* BaseAddr, Int_t NofWords = 0, Bool_t RawMode = kFALSE) const
const UShort_t*NextSubeventData(MBSDataIO* BaseAddr, Int_t NofWords = 0, Bool_t RawMode = kFALSE) const
UInt_tNextSubeventHeader(MBSDataIO* BaseAddr) const
virtual Bool_tTObject::Notify()
voidTObject::Obsolete(const char* method, const char* asOfVers, const char* removedFromVers) const
static voidTObject::operator delete(void* ptr)
static voidTObject::operator delete(void* ptr, void* vp)
static voidTObject::operator delete[](void* ptr)
static voidTObject::operator delete[](void* ptr, void* vp)
void*TObject::operator new(size_t sz)
void*TObject::operator new(size_t sz, void* vp)
void*TObject::operator new[](size_t sz)
void*TObject::operator new[](size_t sz, void* vp)
TObject&TObject::operator=(const TObject& rhs)
virtual voidTObject::Paint(Option_t* option = "")
virtual voidTObject::Pop()
voidPrint(const Char_t* Text, UInt_t TimeStamp = 0)
virtual Int_tTObject::Read(const char* name)
virtual voidTObject::RecursiveRemove(TObject* obj)
virtual voidReset(Int_t InitValue = 0, Bool_t DataOnly = kFALSE)
voidTObject::ResetBit(UInt_t f)
virtual voidTObject::SaveAs(const char* filename = "", Option_t* option = "") constMENU
virtual voidTObject::SavePrimitive(ostream& out, Option_t* option = "")
voidTObject::SetBit(UInt_t f)
voidTObject::SetBit(UInt_t f, Bool_t set)
virtual voidTObject::SetDrawOption(Option_t* option = "")MENU
static voidTObject::SetDtorOnly(void* obj)
voidSetFakeMode(const Bool_t FakeMode = kTRUE)
static voidTObject::SetObjectStat(Bool_t stat)
voidSetReplayMode(const Bool_t ReplayMode = kTRUE)
voidSetScaleDown(Int_t ScaleDown)
virtual voidTObject::SetUniqueID(UInt_t uid)
virtual voidShowMembers(TMemberInspector& insp)
virtual voidStreamer(TBuffer& b)
voidStreamerNVirtual(TBuffer& b)
virtual voidTObject::SysError(const char* method, const char* msgfmt) const
Bool_tTObject::TestBit(UInt_t f) const
Int_tTObject::TestBits(UInt_t f) const
Bool_tTreeToBeWritten() const
virtual voidTObject::UseCurrentStyle()
virtual voidTObject::Warning(const char* method, const char* msgfmt) const
virtual Int_tTObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0)
virtual Int_tTObject::Write(const char* name = 0, Int_t option = 0, Int_t bufsize = 0) const
voidWriteTree(const Bool_t WriteFlag = kTRUE)
protected:
Int_tCalcTimeRS()
virtual voidTObject::DoError(int level, const char* location, const char* fmt, va_list va) const
voidTObject::MakeZombie()
voidSetTimeStamp(Int_t TimeStamp)

Data Members

public:
enum TObject::EStatusBits { kCanDelete
kMustCleanup
kObjInCanvas
kIsReferenced
kHasUUID
kCannotPick
kNoContextMenu
kInvalidObject
};
enum TObject::[unnamed] { kIsOnHeap
kNotDeleted
kZombie
kBitMask
kSingleKey
kOverwrite
kWriteDelete
};
protected:
TBranch*fBranch! ptr to event to be used in TTree::Branch()
Int_tfClockNsecsnano secs of current second
Int_tfClockResclock resolution in nsecs
Int_tfClockSecsseconds since January 1, 1970
Int_tfEventNumberevent number provided by MBS
Bool_tfFakeMode! kTRUE if fake mode on
TObjArrayfLofHBXs! list of hit buffer wrappers, indexed by hit buffer
TObjArrayfLofSubevents! list of subevents
Int_tfNofEntriesnumber of entries in ROOT tree (replay mode only)
Int_tfNofEventsnumber of events collected so far
Bool_tfReplayMode! kTRUE if replay mode on
Int_tfScaleDownindividual scale down factor
UInt_tfSubtype... subtype
Int_tfTimeRStime (ROOT style)
TTree*fTreeIn! tree to read data from ROOT file
TTree*fTreeOut! tree to store data in ROOT format
Int_tfTriggertrigger number
UInt_tfTypeevent type
Bool_tfWriteTree! kTRUE if tree data should be written to file

Class Charts

Inheritance Inherited Members Includes Libraries
Class Charts

Function documentation

TUsrEvent()
__________________________________________________________________[C++ CTOR]

 Name:           TUsrEvent
 Purpose:        Base class for user-defined events
 Arguments:      --
 Results:        --
 Exceptions:
 Description:    Class constructor
 Keywords:

const UShort_t * NextSubevent(MBSDataIO* BaseAddr, Int_t NofWords = 0, Bool_t RawMode = kFALSE) const
________________________________________________________________[C++ METHOD]

 Name:           TUsrEvent::NextSubevent
 Purpose:        Get next subevent
 Arguments:      const MBSDataIO * BaseAddr -- pointer to base of MBS data
                 Int_t NofWords             -- expected number of data words
                 Bool_t RawMode             -- pass data as is, don't decode
                                               subevent structure
 Results:        const UShort_t * SevtData  -- pointer to current (unpacked) data
 Exceptions:
 Description:    Unpacks next subevent from current event.
 Keywords:

UInt_t NextSubeventHeader(MBSDataIO* BaseAddr) const
________________________________________________________________[C++ METHOD]

 Name:           TUsrEvent::NextSubeventHeader
 Purpose:        Get next subevent header
 Arguments:      const MBSDataIO * BaseAddr -- pointer to base of MBS data
 Results:        UInt_t SevtType            -- subevent type
 Exceptions:
 Description:    Unpacks next subevent header from current event.
 Keywords:

const UShort_t * NextSubeventData(MBSDataIO* BaseAddr, Int_t NofWords = 0, Bool_t RawMode = kFALSE) const
________________________________________________________________[C++ METHOD]

 Name:           TUsrEvent::NextSubeventData
 Purpose:        Get next subevent
 Arguments:      const MBSDataIO * BaseAddr -- pointer to base of MBS data
                 Int_t NofWords             -- expected number of data words
                 Bool_t RawMode             -- pass data as is, don't decode
                                               subevent structure
 Results:        const UShort_t * SevtData  -- pointer to current (unpacked) data
 Exceptions:
 Description:    Unpacks next subevent from current event.
 Keywords:

Int_t CalcTimeDiff(TUsrEvent* Event) const
________________________________________________________________[C++ METHOD]

 Name:           TUsrEvent::CalcTimeDiff
 Purpose:        Calculate time with respect to event
 Arguments:      TUsrEvent * BaseEvent      -- event used as time base
 Results:        Int_t TimeDiff             -- time diff in microsecs
 Exceptions:
 Description:    Calculates time difference from internal secs/nsecs values.
                 Result is given in units of 100 micro seconds so it may be
                 used as time stamp via TObject::SetUniqueID().
 Keywords:

Int_t CalcTimeRS()
________________________________________________________________[C++ METHOD]

 Name:           TUsrEvent::CalcTimeRS
 Purpose:        Calculate time in ROOT format
 Arguments:
 Results:        Int_t TimeRS           -- time in ROOT format
 Exceptions:
 Description:    Calculates time from internal values and converts it to
                 ROOT format. Result is stored in fTimeRS.
 Keywords:

Int_t FillSevtFromHB(TUsrHBX* HBX, Int_t Hidx, Bool_t FillHisto = kTRUE, Int_t Didx = TUsrHit::kHitEnergy)
________________________________________________________________[C++ METHOD]

 Name:           TUsrEvent::FillSevtFromHB
 Purpose:        Fill subevent from hitbuffer
 Arguments:      TUsrHBX * HBX     -- pointer to hit buffer
                 Int_t Hidx        -- current index in hit buffer
                 Bool_t FillHisto  -- kTRUE -> write hit data to histogram
                 Int_t Didx        -- data index within hit
 Results:        Int_t NextIndex   -- index to be used in next call, -1 at end
 Exceptions:
 Description:    Writes hit data to subevent storage. Stops at end of an event.
 Keywords:

Bool_t FillEventFromHB(TArrayI& LofIndices, Bool_t FillHisto = kTRUE, Int_t Didx = TUsrHit::kHitEnergy, Int_t InitValue = 0)
________________________________________________________________[C++ METHOD]

 Name:           TUsrEvent::FillEventFromHB
 Purpose:        Fill event from hitbuffer
 Arguments:      TArrayI & LofIndices   -- array of hitbuffer indices,
                                           has to have size=0 on start
                 Bool_t FillHisto       -- kTRUE -> write hit data to histogram
                 Int_t Didx             -- data index within hit
                 Int_t InitValue        -- init value to reset event vector
 Results:        kTRUE/kFALSE
 Exceptions:
 Description:   Loops thru hitbuffers and fills subvent storage event by event.
 Keywords:

void Print(const Char_t* Text, UInt_t TimeStamp = 0)
________________________________________________________________[C++ METHOD]

 Name:           TUsrEvent::Print
 Purpose:        Output time stamp
 Arguments:      Char_t * Text     -- text to be printed
                 UInt_t TimeStamp  -- time stamp
 Results:
 Exceptions:
 Description:    Outputs a time stamp message
 Keywords:

~TUsrEvent()
{ fLofSubevents.Delete(); fLofHBXs.Delete(); }
void SetScaleDown(Int_t ScaleDown)
{ fScaleDown = ScaleDown; }
Int_t GetScaleDown() const
{ return(fScaleDown); }
Int_t GetClockSecs() const
{ return(fClockSecs); }
Int_t GetClockNsecs() const
{ return(fClockNsecs); }
Int_t GetTimeStamp() const
{ return(GetUniqueID()); }
Int_t GetTimeRS() const
{ return(fTimeRS); }
TTree * GetTreeIn() const
{ return(fTreeIn); }
TTree * GetTreeOut() const
{ return(fTreeOut); }
void WriteTree(const Bool_t WriteFlag = kTRUE)
Bool_t TreeToBeWritten() const
{ return(fWriteTree); }
void SetReplayMode(const Bool_t ReplayMode = kTRUE)
Bool_t IsReplayMode() const
{ return(fReplayMode); }
void SetFakeMode(const Bool_t FakeMode = kTRUE)
Bool_t IsFakeMode() const
{ return(fFakeMode); }
Int_t GetNofEvents() const
{ return(fNofEvents); }
Bool_t IsModScaleDown() const
{ return((fNofEvents % fScaleDown) == 0); }
void AddSubevent(TObject* Subevent, Int_t SevtSerial = -1)
 list of subevents
TObjArray * GetLofSubevents()
{ return(&fLofSubevents); }
TObject * GetSubevent(Int_t SevtSerial)
{ return(fLofSubevents.At(SevtSerial)); }
Int_t GetNofSubevents() const
{ return(fLofSubevents.GetEntries()); }
void AddHBX(TUsrHBX* HBX, Int_t SevtSerial = -1)
 list of hit buffers
TUsrHBX * GetHBX(Int_t SevtSerial)
{ return((TUsrHBX *) fLofHBXs.At(SevtSerial)); }
void Reset(Int_t InitValue = 0, Bool_t DataOnly = kFALSE)
{}
void Help()
{ gSystem->Exec(Form("mrbHelp %s", this->ClassName())); }
void SetTimeStamp(Int_t TimeStamp)
{ SetUniqueID(TimeStamp); }



Revision: $Id: TUsrEvent.h,v 1.7 2011/09/16 12:12:31 Marabou Exp $

ROOT page - Home page - Class index - Top of the page

This page has been automatically generated by use of ROOT's THtml class. If you have any comments or suggestions about the page layout send a mail to Marabou Support.