BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
DummyLoadOldROOTAlg.cc
Go to the documentation of this file.
1
3#include "GaudiKernel/MsgStream.h"
4
5#include "TFile.h"
6#include "TSystem.h"
8DummyLoadOldROOTAlg::DummyLoadOldROOTAlg( const std::string& name, ISvcLocator* pSvcLocator )
9 : Algorithm( name, pSvcLocator ) {
10 declareProperty( "OldRootList", m_string_vec );
11}
12
14 MsgStream log( msgSvc(), name() );
15
16 std::vector<std::string>::iterator it;
17 for ( it = m_string_vec.begin(); it != m_string_vec.end(); ++it )
18 {
19 TString tmpfn = ( *it ).c_str();
20 gSystem->ExpandPathName( tmpfn );
21
22 TFile* tmp = new TFile( tmpfn );
23 log << MSG::DEBUG << "Try to Load File: " << *it << endmsg;
24 if ( !tmp )
25 {
26 log << MSG::WARNING << "Load File Failed: " << *it << endmsg;
27 continue;
28 }
29 }
30 return StatusCode::SUCCESS;
31}
32
33StatusCode DummyLoadOldROOTAlg::execute() { return StatusCode::SUCCESS; }
34
35StatusCode DummyLoadOldROOTAlg::finalize() { return StatusCode::SUCCESS; }
DECLARE_COMPONENT(BesBdkRc)
IMessageSvc * msgSvc()
DummyLoadOldROOTAlg(const std::string &name, ISvcLocator *pSvcLocator)