v2.10-0 (21000JUN2005)

Go4EventServer
Class TGo4FileStore


class TGo4FileStore
derived from TGo4EventStore

Event store which fills entries to an own root TTree in a TFile. In contrast to TreeStore, we do not use the main
go4 tree, but an independent one which need not
correspond with the entry indices of all previous
events. Disadvantage: difficult to correlate to input
events; advantage: one entry of this tree may be composed
from several subsequent input event entries...

Author:
J. Adamczewski
Since: 1/2001

Field Summary
 private Bool_tfbBranchExists
          True if branch already exists.
 const static const Text_t[]fgcEVBRANCHNAME
          Standard go4 name of the branch used in all treestore
and treesource implementations.
 const static const Text_t[]fgcFILESUF
          Standard suffix for file name
 const static const Text_t[]fgcTREESUF
          Standard go4 suffix for tree name
 const static const Int_tfgiFILESPLITSIZE
          size in bytes for root tree-filesplit mechanism.
 private Int_tfiBufsize
          buffer size for tree branch.
 private Int_tfiFillCount
          counter of filled events.
 private Int_tfiSplit
          TBranch splitlevel.
 private TGo4EventElement*fxEvent
          Points to event structure to be filled into branch.
 private TFile*fxFile
           
 private TTree*fxTree
           

Fields inherited from interface Go4Event.TGo4EventStore
fguTXTLEN

Fields inherited from class TNamed
fName, fTitle

Constructor Summary
TGo4FileStore()
           
TGo4FileStore(const char * name, Int_t splitlevel, Int_t compression, Bool_t overwrite, Int_t autosavesize, Int_t bufsize)
           
TGo4FileStore(TGo4FileStoreParameter* par)
           

Destructor Summary
 virtual synchronized ~TGo4FileStore()
           

Method Summary
 TTree*GetTree()
          Access to the Tree structure, for framework
 voidSetAutoSave(Int_t bytesinterval)
          Set the tree autosave byte interval.
 voidSetCompression(Int_t comp)
          Set the file compression level.
 virtual Int_tStore(TGo4EventElement* event)
          Stores eventelement event into the storage implementation.
 virtual Int_tStore(TGo4Parameter* cali)
          Saves a calibration object correllated with the current event into the storage.
 virtual Int_tStore(TGo4Condition* conny)
          Saves a condition correllated with the current event into the storage.
 virtual Int_tStore(TGo4Fitter* fitter)
          Saves a fitter correllated with the current event into the storage.
 virtual Int_tStore(TFolder* fold)
          Saves a complete objects folder correllated with the current event into the storage.
 private voidWriteToStore(TNamed* ob)
          used by all Store methods to write with referencing event number in name

Methods inherited from interface Go4Event.TGo4EventStore
Clear

Methods inherited from class TNamed
operator=, Clone, Compare, Copy, FillBuffer, GetName, GetTitle, Hash, IsSortable, SetName, SetNameTitle, SetTitle, ls, Print, Sizeof, Class, Class_Name, Class_Version, Dictionary, IsA, ShowMembers, Streamer, StreamerNVirtual, DeclFileName, ImplFileLine, ImplFileName, DeclFileLine

Field Detail

fbBranchExists

private Bool_t fbBranchExists
True if branch already exists. Used for automatic creation
of new event branch within Store method.

fgcEVBRANCHNAME

public const static const Text_t[] fgcEVBRANCHNAME
Standard go4 name of the branch used in all treestore
and treesource implementations.

fgcFILESUF

public const static const Text_t[] fgcFILESUF
Standard suffix for file name

fgcTREESUF

public const static const Text_t[] fgcTREESUF
Standard go4 suffix for tree name

fgiFILESPLITSIZE

public const static const Int_t fgiFILESPLITSIZE
size in bytes for root tree-filesplit mechanism.

fiBufsize

private Int_t fiBufsize
buffer size for tree branch.

fiFillCount

private Int_t fiFillCount
counter of filled events.

fiSplit

private Int_t fiSplit
TBranch splitlevel.

fxEvent

private TGo4EventElement* fxEvent
Points to event structure to be filled into branch.

fxFile

private TFile* fxFile

fxTree

private TTree* fxTree
Constructor Detail

TGo4FileStore

public TGo4FileStore()

TGo4FileStore

public TGo4FileStore(const char * name, Int_t splitlevel, Int_t compression, Bool_t overwrite, Int_t autosavesize, Int_t bufsize)

TGo4FileStore

public TGo4FileStore(TGo4FileStoreParameter* par)
Method Detail

~TGo4FileStore

public virtual synchronized ~TGo4FileStore()
Method Detail

GetTree

public TTree* GetTree()
Access to the Tree structure, for framework

SetAutoSave

public void SetAutoSave(Int_t bytesinterval)
Set the tree autosave byte interval. May be changed on the fly.

SetCompression

public void SetCompression(Int_t comp)
Set the file compression level. May be changed on the fly.

Store

public virtual Int_t Store(TGo4EventElement* event)
Stores eventelement event into the storage implementation.
May be a file, a root tree, a socket to a viewer...

Store

public virtual Int_t Store(TGo4Parameter* cali)
Saves a calibration object correllated with the current event into the storage.

Store

public virtual Int_t Store(TGo4Condition* conny)
Saves a condition correllated with the current event into the storage.

Store

public virtual Int_t Store(TGo4Fitter* fitter)
Saves a fitter correllated with the current event into the storage.

Store

public virtual Int_t Store(TFolder* fold)
Saves a complete objects folder correllated with the current event into the storage.

WriteToStore

private void WriteToStore(TNamed* ob)
used by all Store methods to write with referencing event number in name

Association Links

to Class TGo4EventElement

Points to event structure to be filled into branch.

J.Adamczewski, M.Al-Turany, D.Bertini, H.G.Essel, S.Linev

30-06-2005