17 #include "TDirectory.h"
33 fbBranchExists(kFALSE),
39 GO4TRACE((15,
"TGo4BackStore::TGo4BackStore()", __LINE__, __FILE__));
46 fbBranchExists(kFALSE),
52 GO4TRACE((15,
"TGo4BackStore::TGo4BackStore(TGo4BackStoreParameter* par)", __LINE__, __FILE__));
55 TGo4Log::Error(
"TGo4BackStoreParameter is not specified in TGo4BackStore constructor");
62 SetName(par->GetName());
64 const char* lastname = par->GetTitle();
65 const char* oldname = lastname;
66 lastname=strstr(oldname,
"/");
70 lastname=strstr(oldname,
"/");
72 TString buffer = oldname;
74 TDirectory *dirsav = gDirectory;
76 fxTree =
new TTree(buffer.Data(),
"Go4BackStore");
79 TGo4Log::Debug(
" Tree %s has been created in memory ",buffer.Data());
85 GO4TRACE((15,
"TGo4BackStore::~TGo4BackStore()", __LINE__, __FILE__));
129 GO4TRACE((12,
"TGo4BackStore::Store(TGo4EventElement*)", __LINE__, __FILE__));
138 TString topbranchname(
fxEvent->GetName());
140 TBranch* go4branch=
fxTree->GetBranch(topbranchname.Data());
144 TGo4Log::Debug(
" BackStore: Found existing branch %s , continue filling ",topbranchname.Data() );
146 go4branch->SetAddress(&
fxEvent);
155 TGo4Log::Debug(
" BackStore: Created new branch %s ", topbranchname.Data());
171 Double_t totbytes=
fxTree->GetTotBytes();
176 fxTree->GetName(), totbytes);
virtual void makeBranch(TBranch *parent)
TGo4EventElement * fxEvent
void Reset(Bool_t onlyclearflag=kFALSE)
static const char * fgcTREESUF
static const Int_t fgiMAXAUTOBYTES
static const char * fgcEVBRANCHNAME
Int_t GetSplitlevel() const
virtual Int_t Store(TGo4EventElement *event)
static void Error(const char *text,...)
static void Debug(const char *text,...)