Load hierarchy into params DB
void writeConfig(const char* macroName){
//
// must be run on www.star.bnl.gov
// since DbFill has "localhost" hardcoded in
//
gSystem->Load("St_base");
gSystem->Load("StChain");
gSystem->Load("St_Tables");
// DB-specific libs
gSystem->Load("StDbLib");
gSystem->Load("StDbBroker");
gSystem->Load("St_db_Maker");
gROOT->LoadMacro(macroName);
St_Table* dat=(St_Table*)CreateTable();
StDbBroker broker;
St_tableDescriptor *rowTL = ((St_Table*)dat)->GetRowDescriptors();
int nElements = rowTL->GetNRows();
tableDescriptor_st *elem= rowTL->GetTable();
StDbBroker::Descriptor *descriptor = (StDbBroker::Descriptor *)elem;
broker.SetDictionary(nElements,descriptor);
broker.SetTableName (dat->GetName());
broker.SetStructName(dat->GetTitle());
broker.SetStructSize(dat->GetRowSize());
broker.SetNRows(dat->GetNRows());
broker.DbInit("params");
char** comments = broker->GetComments(dat);
void* pdata = (void*)((St_tables_hierarchy*)dat)->GetTable();
broker.Fill(pdata,comments);
};
ROOT page - Class index - Top of the page
This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.