GSI Object Oriented Online Offline (Go4)
GO4-5.3.2
|
#include <TGo4FileSource.h>
Public Member Functions | |
TGo4FileSource () | |
TGo4FileSource (TGo4FileSourceParameter *par) | |
TGo4FileSource (const char *name) | |
virtual | ~TGo4FileSource () |
virtual Bool_t | BuildEvent (TGo4EventElement *dest) |
Public Member Functions inherited from TGo4EventSource | |
TGo4EventSource (const char *name) | |
virtual | ~TGo4EventSource () |
TGo4EventSource () | |
virtual void | Clear (Option_t *opt="") |
Int_t | GetCreateStatus () const |
Int_t | GetEventStatus () const |
const char * | GetErrMess () const |
virtual const char * | GetActiveName () |
virtual Bool_t | CheckEventClass (TClass *cl) |
Static Public Member Functions | |
static TList * | ProducesFilesList (const char *mask) |
Private Member Functions | |
Bool_t | OpenNextFile () |
Bool_t | CloseCurrentFile () |
Private Attributes | |
TFile * | fxFile |
TTree * | fxTree |
Long64_t | fiMaxEvents |
Long64_t | fiCurrentEvent |
long int | fiGlobalEvent |
Bool_t | fbActivated |
TGo4EventElement * | fxTopEvent |
TList * | fxFilesNames |
TString | fxCurrentFileName |
Additional Inherited Members | |
Static Public Attributes inherited from TGo4EventSource | |
static const Int_t | fgiTIMEOUTDEFAULT =1 |
Protected Types inherited from TGo4EventSource | |
enum | { fguTXTLEN = 256 } |
Protected Member Functions inherited from TGo4EventSource | |
void | SetErrMess (const char *txt) |
void | SetEventStatus (Int_t status) |
void | SetCreateStatus (Int_t status) |
void | ThrowError (Int_t creastat, Int_t errstat, const char *message,...) |
void | ThrowEOF (Int_t creastat, Int_t errstat, const char *message,...) |
Raw event source which reads entries from a root TTree in a TFile. File is opened by ctor; method BuildEvent() iterates over tree. Needs pointer to external reference to event structure class which must match the structure of the tree entry New since 10/2004: Name of event element defines tree subbranch to be activated as partial input
Definition at line 36 of file TGo4FileSource.h.
TGo4FileSource::TGo4FileSource | ( | ) |
Definition at line 65 of file TGo4FileSource.cxx.
TGo4FileSource::TGo4FileSource | ( | TGo4FileSourceParameter * | par | ) |
Definition at line 47 of file TGo4FileSource.cxx.
References fxFilesNames, OpenNextFile(), ProducesFilesList(), and TGo4EventSource::ThrowError().
TGo4FileSource::TGo4FileSource | ( | const char * | name | ) |
Definition at line 30 of file TGo4FileSource.cxx.
References fxFilesNames, OpenNextFile(), ProducesFilesList(), and TGo4EventSource::ThrowError().
|
virtual |
Definition at line 79 of file TGo4FileSource.cxx.
References CloseCurrentFile(), and fxFilesNames.
|
virtual |
Fill the destination event dest from the tree. If end of tree is reached, the current event counter is reset and a kFALSE value is returned.
Reimplemented from TGo4EventSource.
Definition at line 200 of file TGo4FileSource.cxx.
References fbActivated, fiCurrentEvent, fiGlobalEvent, fiMaxEvents, fxCurrentFileName, fxTopEvent, fxTree, TGo4Log::Info(), OpenNextFile(), TGo4EventElement::synchronizeWithTree(), TGo4EventSource::ThrowEOF(), and TGo4EventSource::ThrowError().
Referenced by TMeshB3InputEvent::Fill(), TMeshB1OutputEvent::Fill(), TMeshB3OutputEvent::Fill(), TMeshB2InputEvent::Fill(), TMeshB2OutputEvent::Fill(), TMeshB12OutputEvent::Fill(), TMeshFinalEvent::Fill(), TMeshB1InputEvent::Fill(), TMeshRawEvent::Fill(), and TGo4SimpleEvent::Fill().
|
private |
Close currently open file.
Definition at line 182 of file TGo4FileSource.cxx.
References fbActivated, fiCurrentEvent, fiMaxEvents, fxCurrentFileName, fxFile, fxTopEvent, fxTree, and TGo4Log::Info().
Referenced by OpenNextFile(), and ~TGo4FileSource().
|
private |
Open next file from the files list.
Definition at line 150 of file TGo4FileSource.cxx.
References CloseCurrentFile(), fiMaxEvents, fxCurrentFileName, fxFile, fxFilesNames, fxTree, TGo4EventSource::SetCreateStatus(), and TGo4EventSource::ThrowError().
Referenced by BuildEvent(), and TGo4FileSource().
|
static |
Definition at line 89 of file TGo4FileSource.cxx.
References TGo4FileStore::fgcFILESUF.
Referenced by TGo4MbsFile::AddFileName(), and TGo4FileSource().
|
private |
This flag is used for lazy init of tree in Eventbuilding methods.
Definition at line 72 of file TGo4FileSource.h.
Referenced by BuildEvent(), and CloseCurrentFile().
|
private |
Event number in current tree.
Definition at line 66 of file TGo4FileSource.h.
Referenced by BuildEvent(), and CloseCurrentFile().
|
private |
Global event number, starting from the first tree.
Definition at line 69 of file TGo4FileSource.h.
Referenced by BuildEvent().
|
private |
Number of events stored in the Tree. Used to check if the complete tree is already read.
Definition at line 63 of file TGo4FileSource.h.
Referenced by BuildEvent(), CloseCurrentFile(), and OpenNextFile().
|
private |
current name of the file
Definition at line 81 of file TGo4FileSource.h.
Referenced by BuildEvent(), CloseCurrentFile(), and OpenNextFile().
|
private |
Definition at line 57 of file TGo4FileSource.h.
Referenced by CloseCurrentFile(), and OpenNextFile().
|
private |
list of files names
Definition at line 78 of file TGo4FileSource.h.
Referenced by OpenNextFile(), TGo4FileSource(), and ~TGo4FileSource().
|
private |
pointer to top branch event
Definition at line 75 of file TGo4FileSource.h.
Referenced by BuildEvent(), and CloseCurrentFile().
|
private |
Definition at line 59 of file TGo4FileSource.h.
Referenced by BuildEvent(), CloseCurrentFile(), and OpenNextFile().