48 MsgStream log(
msgSvc(), name());
50 log << MSG::INFO <<
"in initialize()" << endmsg;
52 SmartIF<IJobOptionsSvc> iSvc(serviceLocator()->service(
"JobOptionsSvc"));
53 if ( iSvc.isValid() ) {
55 const std::vector<const Property*>* ps = 0;
56 if ( iSvc->getProperties(
"RootCnvSvc") != 0 )
57 ps = iSvc->getProperties(
"RootCnvSvc");
58 if ( iSvc->getProperties(
"EventCnvSvc") != 0 )
59 ps = iSvc->getProperties(
"EventCnvSvc");
60 if ( iSvc->getProperties(
"WriteDst") != 0 )
61 ps = iSvc->getProperties(
"WriteDst");
65 for(
int i=0;i<ps->size();i++)
67 if( (*ps)[i]->name() ==
"digiRootOutputFile" )
70 m_dstOutput = (*ps)[i]->toString();
71 std::cout<<
"read from JobOptionSvc, dstOutput: "<< m_dstOutput<<std::endl;
80 log << MSG::INFO <<
"RootInteface TotalFileNum: "<<m_rootInterface->
getTotalFileNum()<<endreq;
81 std::cout<<
"getTotalFileNum: "<<m_rootInterface->
getTotalFileNum()<<std::endl;
87 std::cout<<
"the input file num != output file number, please check your jobOptions"<<std::endl;
96 return StatusCode::SUCCESS;
153 MsgStream log(
msgSvc(), name());
154 log << MSG::INFO <<
"reading event data from DST"<<endreq;
156 SmartDataPtr<Event::EventHeader> eventHeader(eventSvc(),
"/Event/EventHeader");
159 log << MSG::FATAL <<
"Could not find EventHeader." << endreq;
160 return StatusCode::FAILURE;
163 m_runNo=eventHeader->runNumber();
164 m_eventId=eventHeader->eventNumber();
165 log << MSG::DEBUG <<
"run, evtnum = " << m_runNo <<
" , "<< m_eventId <<endreq;
170 log << MSG::FATAL <<
"Could not find EvtRecEvent." << endreq;
171 return StatusCode::FAILURE;
173 log << MSG::DEBUG <<
"ncharg, nneu, tottks = "
174 << evtRecEvent->totalCharged() <<
" , "
175 << evtRecEvent->totalNeutral() <<
" , "
176 << evtRecEvent->totalTracks() <<endreq;
177 m_totalCharged = evtRecEvent->totalCharged();
178 m_totalNeutral = evtRecEvent->totalNeutral();
179 m_totalTrks = evtRecEvent->totalTracks();
180 return StatusCode::SUCCESS;