52 |
// CORE ROUTINE |
// CORE ROUTINE |
53 |
// |
// |
54 |
// |
// |
55 |
int AcCore(UInt_t run, TFile *file, TSQLServer *dbc, Int_t Acargc, char *Acargv[]){ |
int AcCore(UInt_t run, TFile *file, GL_TABLES *glt, Int_t Acargc, char *Acargv[]){ |
56 |
Int_t i = 0; |
Int_t i = 0; |
57 |
Bool_t verbose = false; |
Bool_t verbose = false; |
58 |
Bool_t debug = false; |
Bool_t debug = false; |
383 |
// |
// |
384 |
// prepare the timesync for the db |
// prepare the timesync for the db |
385 |
// |
// |
386 |
// if ( !dbc->IsConnected() ) throw -705; |
TString host = glt->CGetHost(); |
387 |
|
TString user = glt->CGetUser(); |
388 |
|
TString psw = glt->CGetPsw(); |
389 |
|
TSQLServer *dbc = TSQLServer::Connect(host.Data(),user.Data(),psw.Data()); |
390 |
|
if ( !dbc->IsConnected() ) throw -705; |
391 |
dbtime = new GL_TIMESYNC(runinfo->ID_ROOT_L0,"ID",dbc); |
dbtime = new GL_TIMESYNC(runinfo->ID_ROOT_L0,"ID",dbc); |
392 |
// |
// |
393 |
// Search in the DB the path and name of the LEVEL0 file to be processed. |
// Search in the DB the path and name of the LEVEL0 file to be processed. |
463 |
// |
// |
464 |
if ( dbc ){ |
if ( dbc ){ |
465 |
dbc->Close(); |
dbc->Close(); |
466 |
// delete dbc; |
delete dbc; |
467 |
}; |
}; |
468 |
// |
// |
469 |
if ( verbose ) printf("\n Ready to start! \n\n Processed events: \n\n"); |
if ( verbose ) printf("\n Ready to start! \n\n Processed events: \n\n"); |