GSI Object Oriented Online Offline (Go4)  GO4-6.1.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Private Attributes | Friends | List of all members
TGo4HDF5Source Class Reference

#include <TGo4HDF5Source.h>

+ Inheritance diagram for TGo4HDF5Source:

Public Member Functions

 TGo4HDF5Source ()
 TGo4HDF5Source (TGo4HDF5SourceParameter *par)
 TGo4HDF5Source (const char *name)
virtual ~TGo4HDF5Source ()
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)

Protected Member Functions

virtual void OpenFile (const char *fname)
virtual void BuildDataSet (TGo4EventElement *event)
virtual void DeleteDataSet ()
- 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,...)

Private Member Functions

Bool_t OpenNextFile ()
Bool_t CloseCurrentFile ()
- Private Member Functions inherited from TGo4HDF5Adapter
 TGo4HDF5Adapter ()
virtual ~TGo4HDF5Adapter ()
virtual void CloseFile ()
void BuildDataType (TGo4EventElement *event, TGo4HDF5DataHandle *parent=0, Int_t index=0)
size_t ScanEventSize (TGo4EventElement *event)
UInt_t ConvertFileMode (Go4_H5_File_Flags flags)

Private Attributes

Char_t * fxReadBuffer
size_t fiReadOffset
TList * fxFilesNames
TString fxCurrentFileName
- Private Attributes inherited from TGo4HDF5Adapter
H5::H5File * fxFile
Bool_t fbDataSetExists
UInt_t fiFlags
hsize_t fiFillCount


class TGo4HDF5DataHandle
class TGo4HDF5BasicDataHandle

Additional Inherited Members

- Static Public Attributes inherited from TGo4EventSource
static const Int_t fgiTIMEOUTDEFAULT =1
- Protected Types inherited from TGo4EventSource
enum  { fguTXTLEN = 256 }
- Static Private Member Functions inherited from TGo4HDF5Adapter
static void AddSubHandle (TGo4HDF5DataHandle *handle, const char *name, const char *type, size_t size, size_t memberoffset, const char *membername, const char *classname, TClass *valueclass)
static void FillTypeInfo (TGo4HDF5DataHandle *handle, TClass *rootclass, const char *basename=0)
static void FillTypeInfo (TGo4HDF5DataHandle *handle, const char *membername, const char *memtypename, size_t memberoffset=0, Int_t arraydim=0, TDataMember *member=0)
- Static Private Attributes inherited from TGo4HDF5Adapter
static const char * fgcFILESUF = ".h5"

Detailed Description

Event source which reads entries from a dataset in a hdf5 formatted file names of elements in hdf5 data must match the members of the input event class

Definition at line 34 of file TGo4HDF5Source.h.

Constructor & Destructor Documentation

TGo4HDF5Source::TGo4HDF5Source ( )

Definition at line 57 of file TGo4HDF5Source.cxx.

TGo4HDF5Source::TGo4HDF5Source ( TGo4HDF5SourceParameter par)
TGo4HDF5Source::TGo4HDF5Source ( const char *  name)
TGo4HDF5Source::~TGo4HDF5Source ( )

Definition at line 63 of file TGo4HDF5Source.cxx.

References CloseCurrentFile(), and fxFilesNames.

Member Function Documentation

void TGo4HDF5Source::BuildDataSet ( TGo4EventElement event)
Bool_t TGo4HDF5Source::BuildEvent ( TGo4EventElement dest)

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 226 of file TGo4HDF5Source.cxx.

References BuildDataSet(), TGo4Log::Error(), TGo4HDF5Adapter::fiFillCount, TGo4HDF5Adapter::fxEvent, TGo4HDF5Adapter::fxFile, TGo4HDF5Adapter::fxHandle, go4init::msg, TGo4HDF5DataHandle::Read(), TGo4EventSource::SetErrMess(), and TGo4EventSource::ThrowError().

Bool_t TGo4HDF5Source::CloseCurrentFile ( )
void TGo4HDF5Source::DeleteDataSet ( )

delete dataset resource

Reimplemented from TGo4HDF5Adapter.

Definition at line 217 of file TGo4HDF5Source.cxx.

References TGo4HDF5Adapter::DeleteDataSet(), and fxReadBuffer.

void TGo4HDF5Source::OpenFile ( const char *  fname)

opens the hdf5 file of given name for reading

Implements TGo4HDF5Adapter.

Definition at line 168 of file TGo4HDF5Source.cxx.

References TGo4HDF5Adapter::CloseFile(), TGo4Log::Error(), TGo4HDF5Adapter::fgcFILESUF, TGo4HDF5Adapter::fxFile, TGo4Log::Info(), go4init::msg, and TGo4EventSource::SetErrMess().

Referenced by OpenNextFile().

Bool_t TGo4HDF5Source::OpenNextFile ( )

Open next file from the files list.

Definition at line 134 of file TGo4HDF5Source.cxx.

References CloseCurrentFile(), fxCurrentFileName, fxFilesNames, and OpenFile().

Referenced by TGo4HDF5Source().

TList * TGo4HDF5Source::ProducesFilesList ( const char *  mask)

Definition at line 73 of file TGo4HDF5Source.cxx.

References TGo4HDF5Adapter::fgcFILESUF.

Referenced by TGo4HDF5Source().

Friends And Related Function Documentation

friend class TGo4HDF5BasicDataHandle

Definition at line 37 of file TGo4HDF5Source.h.

friend class TGo4HDF5DataHandle

Definition at line 36 of file TGo4HDF5Source.h.

Member Data Documentation

size_t TGo4HDF5Source::fiReadOffset

begin of real eventdata payload after event object pointer

Definition at line 77 of file TGo4HDF5Source.h.

TString TGo4HDF5Source::fxCurrentFileName

current name of the file

Definition at line 84 of file TGo4HDF5Source.h.

Referenced by CloseCurrentFile(), and OpenNextFile().

TList* TGo4HDF5Source::fxFilesNames

list of files names

Definition at line 81 of file TGo4HDF5Source.h.

Referenced by OpenNextFile(), TGo4HDF5Source(), and ~TGo4HDF5Source().

Char_t* TGo4HDF5Source::fxReadBuffer

read buffer for hdf5

Definition at line 74 of file TGo4HDF5Source.h.

Referenced by DeleteDataSet().

The documentation for this class was generated from the following files: