BOSS 7.0.1
BESIII Offline Software System
Loading...
Searching...
No Matches
RootCnvSvc.cxx
Go to the documentation of this file.
1#define RootCnvSvc_CXX
2#include <iostream>
3#include "GaudiKernel/SmartIF.h"
4#include "GaudiKernel/SvcFactory.h"
5
6#include "GaudiKernel/MsgStream.h"
7#include "GaudiKernel/ISvcLocator.h"
8#include "GaudiKernel/IDataProviderSvc.h"
9#include "GaudiKernel/IDataManagerSvc.h"
10#include "GaudiKernel/RegistryEntry.h"
11#include "GaudiKernel/GenericAddress.h"
12
13#include "RawEvent/DigiEvent.h"
14#include "DstEvent/DstEvent.h"
15#include "McTruth/McEvent.h"
16#include "TrigEvent/TrigEvent.h"//caogf
17#include "HltEvent/HltEvent.h"//fucd
18#include "RootCnvSvc/RootInterface.h"
19
20#include "RootCnvSvc/RootAddress.h"
21#include "RootCnvSvc/RootCnvSvc.h"
22#include "RootCnvSvc/RootEvtSelector.h"
23
24
25#include "RootCnvSvc/Dst/MdcDedxCnv.h"
26#include "RootCnvSvc/Dst/DstCnv.h"
27#include "RootCnvSvc/Digi/EmcDigiCnv.h"
28#include "RootCnvSvc/Mc/EmcMcHitCnv.h"
29#include "RootCnvSvc/Dst/EmcTrackCnv.h"
30#include "RootCnvSvc/EventCnv.h"
31#include "RootCnvSvc/Dst/ExtTrackCnv.h"
32#include "RootCnvSvc/Mc/McCnv.h"
33#include "RootCnvSvc/Mc/McParticleCnv.h"
34#include "RootCnvSvc/Digi/MdcDigiCnv.h"
35#include "RootCnvSvc/Dst/MdcKalTrackCnv.h"
36#include "RootCnvSvc/Mc/MdcMcHitCnv.h"
37#include "RootCnvSvc/Dst/MdcTrackCnv.h"
38#include "RootCnvSvc/Digi/MucDigiCnv.h"
39#include "RootCnvSvc/Mc/MucMcHitCnv.h"
40#include "RootCnvSvc/Dst/MucTrackCnv.h"
41#include "RootCnvSvc/Digi/DigiCnv.h"
42#include "RootCnvSvc/Digi/TofDigiCnv.h"
43#include "RootCnvSvc/Mc/TofMcHitCnv.h"
44#include "RootCnvSvc/Dst/TofTrackCnv.h"
45#include "RootCnvSvc/Digi/LumiDigiCnv.h"
46
47#include "RootCnvSvc/Rec/RecMucTrackCnv.h"
48#include "RootCnvSvc/Rec/RecMdcTrackCnv.h"
49#include "RootCnvSvc/Rec/RecMdcHitCnv.h"
50#include "RootCnvSvc/Rec/RecMdcKalTrackCnv.h"
51#include "RootCnvSvc/Rec/RecMdcKalHelixSegCnv.h"
52#include "RootCnvSvc/Rec/RecMdcDedxCnv.h"
53#include "RootCnvSvc/Rec/RecMdcDedxHitCnv.h"
54#include "RootCnvSvc/Rec/RecTofTrackCnv.h"
55#include "RootCnvSvc/Rec/RecBTofCalHitCnv.h"
56#include "RootCnvSvc/Rec/RecETofCalHitCnv.h"
57#include "RootCnvSvc/Rec/RecMucRecHitCnv.h"
58#include "RootCnvSvc/Rec/RecEmcHitCnv.h"
59#include "RootCnvSvc/Rec/RecEmcClusterCnv.h"
60#include "RootCnvSvc/Rec/RecEmcShowerCnv.h"
61#include "RootCnvSvc/Rec/RecEvTimeCnv.h"
62#include "RootCnvSvc/Rec/RecExtTrackCnv.h"
63#include "RootCnvSvc/Rec/RecTrackCnv.h"
64
65#include "RootCnvSvc/EvtRec/EvtRecCnv.h"
66#include "RootCnvSvc/EvtRec/EvtRecEventCnv.h"
67#include "RootCnvSvc/EvtRec/EvtRecTrackCnv.h"
68#include "RootCnvSvc/EvtRec/EvtRecPrimaryVertexCnv.h"
69#include "RootCnvSvc/EvtRec/EvtRecVeeVertexCnv.h"
70#include "RootCnvSvc/EvtRec/EvtRecPi0Cnv.h"
71#include "RootCnvSvc/EvtRec/EvtRecEtaToGGCnv.h"
72#include "RootCnvSvc/EvtRec/EvtRecDTagCnv.h"
73#include "RootCnvSvc/Rec/RecZddChannelCnv.h"
74
75
76#include "RootCnvSvc/Trig/TrigCnv.h"
77#include "RootCnvSvc/Trig/TrigDataCnv.h"
78
79#include "RootCnvSvc/Hlt/HltCnv.h"
80#include "RootCnvSvc/Hlt/HltRawCnv.h"
81#include "RootCnvSvc/Hlt/HltInfCnv.h"
82#include "RootCnvSvc/Hlt/DstHltInfCnv.h"
83
84#include "RootCnvSvc/EvtHeaderCnv.h"
85#include "RootCnvSvc/EvtNavigatorCnv.h"
86
87#include <math.h>
88
89using namespace std;
90
91// RCS Id for identification of object version
92static const char* rcsid = "$Id: RootCnvSvc.cxx,v 1.68 2015/06/17 03:12:16 dengzy Exp $";
93
94
95// Instantiation of a static factory class used by clients to create
96// instances of this service
97//static const SvcFactory<RootCnvSvc> s_RootCnvSvcFactory;
98//const ISvcFactory& RootCnvSvcFactory = s_RootCnvSvcFactory;
99
100RootCnvSvc::RootCnvSvc(const std::string& name, ISvcLocator* svc)
101 : ConversionSvc(name, svc, ROOT_StorageType), m_minSplit(1), m_evtsel(0)
102{
103 StatusCode sc;
104 MsgStream log(msgSvc(), "RootCnvSvc");
105 log << MSG::DEBUG << "RootCnvSvc::constructor" << endreq;
106
107 IService* isvc = 0;
108 sc = serviceLocator()->getService ("RootEvtSelector", isvc, false);
109 if (!sc.isSuccess()) sc = serviceLocator()->getService ("EventSelector", isvc, false);
110 if (sc.isSuccess()) {
111 sc = isvc->queryInterface(IID_IRootEvtSelector, (void**)&m_evtsel);
112 }
113 if(sc.isFailure()) {
114 log << MSG::WARNING << "Unable to start event selector service within RootCnvSvc" << endreq;
115 }
116
117 m_rootInterface= RootInterface::Instance(log);
118 if (!m_rootInterface) log << MSG::ERROR << "Unable to start Root service within RootCnvSvc" << endreq;
119
120
121
122 //Digi
123 declareProperty("digiTreeName", m_dtreeName="Event"); //"Rec"->"Event"
124
125 declareProperty("digiRootInputFile",m_difileName);
126 //if (m_difileName.size()==0){
127 // m_difileName.push_back("digi.root");
128 //}
129 declareProperty("digiRootOutputFile",m_dofileName = "");
130
131 // Split mode for writing the TTree [0,99]
132 declareProperty("digiSplitMode", m_dsplitMode=m_minSplit);
133 // Buffer size for writing ROOT data
134 declareProperty("digiBufferSize", m_dbufSize=3200000);
135 // ROOT default compression
136 declareProperty("digiCompressionLevel", m_dcompressionLevel=1);
137 declareProperty("selectFromTag", m_selectFromTag=0);
138 declareProperty("tagInputFile", m_tagInputFile);
139 //declareProperty("tagFileFormat", m_tagFileFormat=1);
140
141}
142
144 // Purpose and Method: Setup GLAST's Event Converter Service.
145 // Associate RootCnvSvc with the EventDataSvc
146 // Associate the list of known converters with this RootCnvSvc
147 // configure map of leaves
148
149 MsgStream log(msgSvc(), name());
150 log << MSG::DEBUG << "RootCnvSvc::initialize" << endreq;
151 StatusCode status = ConversionSvc::initialize();
152 if ( status.isSuccess() ) {
153 // ISvcLocator* svclocator = serviceLocator(); [unused for now]
154 IDataProviderSvc *pIDP = 0;
155 // Set event data service
156 status = service("EventDataSvc", pIDP, true);
157 if ( status.isSuccess() ) {
158 status = setDataProvider ( pIDP );
159 }
160 else {
161 return status;
162 }
163
164
165 // Add converters to the service
166 status = addConverters();
167 if ( !status.isSuccess() ) {
168 log << MSG::ERROR << "Unable to add converters to the service" << endreq;
169 return status;
170 }
171
172
173 // Now we have to configure the map of leaves
174 // Which should contain the association of converters with
175 // paths on the TDS
176 for (LeafMap::iterator k = m_leaves.begin(); k != m_leaves.end(); k++ ) {
177 std::string path = (*k).first;
178 for (LeafMap::iterator j = m_leaves.begin(); j != m_leaves.end(); j++ ) {
179 std::string path2 = (*j).first;
180 std::string pp = (*j).first.substr(0, (*j).first.rfind("/"));
181 if ( path == pp && path != (*j).first ) {
182 (*k).second->push_back((*j).second);
183 }
184 }
185 }
186 }
187
188 // get properties and tell RootInterface about files
189 status=initFiles();
190
191 m_rootInterface->setSelectFromTag(m_selectFromTag);
192 m_rootInterface->setTagInputFile(m_tagInputFile);
193 //m_rootInterface->setTagFileFormat(m_tagFileFormat);
194
195 return status;
196}
197
199 MsgStream log(msgSvc(), name());
200 log << MSG::DEBUG << "RootCnvSvc::finalize" << endreq;
201
202 ConversionSvc::finalize();
203 // log << MSG::INFO<<"this is the end of RootCnvsvc finalize"<<endreq;
204 for (LeafMap::iterator k = m_leaves.begin(); k != m_leaves.end(); k++ ) {
205 delete (*k).second;
206 }
207 m_leaves.erase(m_leaves.begin(), m_leaves.end());
208
209 return m_rootInterface->finalize();
210}
211
212StatusCode RootCnvSvc::initFiles () {
213 MsgStream log(msgSvc(), name());
214 log << MSG::DEBUG << "RootCnvSvc::initFiles" << endreq;
215 StatusCode sc=StatusCode::SUCCESS;
216
217 // Use the Job options service to set the Algorithm's parameters
218 // This will retrieve parameters set in the job options file
219 setProperties();
220
221 //Read inpout files files from job options
222 int nSize = m_difileName.size();
223 log<<MSG::INFO<<"Root Input files "<<nSize<<endreq;
224 if(nSize == 0){
225 log<<MSG::INFO<<"Unable to find input file"<<endreq;
226 //return StatusCode::FAILURE;
227 }
228
229 for(int i = 0;i<nSize;i++){
230 facilities::Util::expandEnvVar(&m_difileName[i]);
231 std::string s=m_difileName[i];
232 std::vector<int> wildcardPos;
233 for(int pos=0;pos<s.size();pos++) {
234 pos=s.find_first_of('?',pos);
235 if(pos!=-1) {
236 wildcardPos.push_back(pos);
237 }
238 else{
239 break;
240 }
241 }
242 if(wildcardPos.size()!=0) {
244 int maxNo=pow(10.,(int)wildcardPos.size());
245 if(nEnd!=0&&nEnd<maxNo) maxNo=nEnd;
246 int nStart=facilities::Util::catchOptionVal(&s,0,"&(",")");
247 int i=1;
248 if(nStart!=-1) i=nStart;
249 if(nStart>nEnd) log<<MSG::WARNING<<"file's StartNo>EndNo"<<endreq;
250 for(;i<maxNo;i++){
251 std::vector<int>::iterator it=wildcardPos.end();
252 int id=i;
253 while(it!=wildcardPos.begin()){
254 it--;
255 char c=id%10+48;
256 id /=10;
257 s.replace((*it),1,1,c);
258 }
259 if(access(s.c_str(),0)!=-1) {
260 sc = m_rootInterface->addInput(m_dtreeName,s);
261 if (sc.isFailure()) return sc;
262 }
263 }
264 }
265 else {
266 sc = m_rootInterface->addInput(m_dtreeName,m_difileName[i]);
267 if (sc.isFailure()) return sc;
268 }
269 }
270
271 //facilities::Util::expandEnvVar(&m_difileName[0]);
272 //sc = m_rootInterface->addInput(m_dtreeName,m_difileName[0]);
273 //if (sc.isFailure()) return sc;
274
275
276 //Digi
277 //facilities::Util::expandEnvVar(&m_difileName);
278 facilities::Util::expandEnvVar(&m_dofileName);
279 // sc = m_rootInterface->addInput(m_dtreeName,m_difileName);
280 // if (sc.isFailure()) return sc;
281
282 if (m_dsplitMode<m_minSplit) {
283 log << MSG::WARNING << "RootCnvSvc::initFiles Recon splitlevel cant be lower than "<<m_minSplit<<", reset" << endreq;
284 m_dsplitMode=m_minSplit;
285 }
286
287 if( "" != m_dofileName ){
288 sc=m_rootInterface->addOutput(m_dtreeName,m_dofileName,m_dsplitMode,m_dbufSize,m_dcompressionLevel);
289 }else{
290 log << MSG::WARNING << "No specified digiRootOutputFile!" << endreq;
291 }
292
293 return sc;
294}
295
296
297StatusCode RootCnvSvc::declareObject(const Leaf& leaf) {
298 // Purpose and Method: Callback from each of the individual converters that allows
299 // association of TDS path and converter.
300 MsgStream log(msgSvc(), name());
301 log << MSG::DEBUG << "RootCnvSvc::declareObject " << leaf.path << " classid: " << leaf.clid << endreq;
302 Leaf* ll = new Leaf(leaf);
303 std::pair<LeafMap::iterator, bool> p = m_leaves.insert(LeafMap::value_type( leaf.path, ll) );
304 if( p.second ) {
305 return StatusCode::SUCCESS;
306 }
307 delete ll;
308 return StatusCode::FAILURE;
309}
310
311/// Update state of the service
312StatusCode RootCnvSvc::updateServiceState(IOpaqueAddress* pAddress) {
313
314 // not sure about the use of recid or bank...
315 MsgStream log(msgSvc(), name());
316
317 log << MSG::DEBUG << "RootCnvSvc::updateServiceState" << endreq;
318
319 StatusCode status = INVALID_ADDRESS;
320 IRegistry* ent = pAddress->registry();
321 if ( 0 != ent ) {
322 SmartIF<IDataManagerSvc> iaddrReg(dataProvider());
323 // if ( 0 != iaddrReg ) {
324 status = StatusCode::SUCCESS;
325 std::string path = ent->identifier();
326 LeafMap::iterator itm = m_leaves.find(path);
327 if ( itm != m_leaves.end() ) {
328 Leaf* leaf = (*itm).second;
329 if ( 0 != leaf ) {
330 for ( Leaf::iterator il = leaf->begin(); il != leaf->end(); il++ ) {
331 IOpaqueAddress* newAddr = 0;
332 unsigned long ipars[2] = {0, 0}; //
333 if (m_evtsel) ipars[0]=m_evtsel->getRecId();
334
335 std::string spars[3]={(*il)->path,(*il)->treename,(*il)->branchname};
336
337 StatusCode ir =createAddress(ROOT_StorageType,
338 (*il)->clid,
339 spars,
340 ipars,
341 newAddr);
342 log << MSG::DEBUG << "RootCnvSvc::updateService " << " ***** " <<
343 (*il)->clid << " ***** " << (*il)->path <<endreq;
344
345 if ( ir.isSuccess() ) {
346 ir = iaddrReg->registerAddress((*il)->path, newAddr);
347 if ( !ir.isSuccess() ) {
348 newAddr->release();
349 status = ir;
350 }
351 }
352 }
353 }
354 }
355 }
356 return StatusCode::SUCCESS;
357 }
358
359 StatusCode RootCnvSvc::queryInterface(const InterfaceID& riid, void** ppvInterface) {
360
361 if ( IID_IRootCnvSvc == riid ) {
362 *ppvInterface = (RootCnvSvc*)this;
363 }
364 else {
365 // Interface is not directly availible: try out a base class
366 return ConversionSvc::queryInterface(riid, ppvInterface);
367 }
368 addRef();
369 return StatusCode::SUCCESS;
370 }
371
372 StatusCode RootCnvSvc::createAddress(long int svc_type,
373 const CLID& clid,
374 const std::string* spars,
375 const unsigned long* ipars,
376 IOpaqueAddress*& refpAddress)
377 {
378 MsgStream log( msgSvc(), name() );
379
380 if (svc_type != repSvcType() ) {
381 log << MSG::ERROR << "RootCnvSvc::bad storage type" << svc_type << endreq;
382 return StatusCode::FAILURE;
383 }
384
385 std::string path = spars[0];
386 std::string treename = spars[1];
387 std::string branchname = spars[2];
388 int entry=ipars[0];
389 if (path.size()==0) path="/Event";
390 refpAddress = new RootAddress(ROOT_StorageType,
391 clid,
392 path,treename,branchname,entry);
393 return StatusCode::SUCCESS;
394 }
395
396
397 StatusCode RootCnvSvc::commitOutput(const std::string& output, bool do_commit)
398 {
399
400
401
402 MsgStream log( msgSvc(), name() );
403 log << MSG::INFO << "RootCnvSvc::commitOutput starts." << endreq;
404
405 StatusCode sc=m_rootInterface->fillTrees();
406 if (sc.isFailure())
407 log << MSG::ERROR << "No Root tree was filled" << endreq;
408
409 // objects must be cleared after fill
410 else{
411 TObject* oEvtHeader = m_evtheaderCnv->getWriteObject();
412 if (oEvtHeader) oEvtHeader->Clear();
413 TObject* oEvtNavigator = m_evtnavigatorCnv->getWriteObject();
414 if (oEvtNavigator) oEvtNavigator->Clear();
415 TObject* o=m_dCnv->getWriteObject();
416 if (o) o->Clear();
417 TObject* oDst=m_dstCnv->getWriteObject();
418 if (oDst) oDst->Clear();
419 TObject* oMc=m_mcCnv->getWriteObject();
420 if (oMc) oMc->Clear();
421 TObject* oRecTrack=m_rectrackCnv->getWriteObject();
422 if (oRecTrack) oRecTrack->Clear();
423 TObject* oEvtRecEvent = m_evtRecCnv->getWriteObject();
424 if (oEvtRecEvent) oEvtRecEvent->Clear();
425 TObject* oTrig = m_trigCnv->getWriteObject();
426 if(oTrig) oTrig->Clear();
427 TObject* oHlt = m_hltCnv->getWriteObject();
428 if(oHlt) oHlt->Clear();
429 }
430 m_common.clear();
431
432 return sc;
433 }
434
435 StatusCode RootCnvSvc::createAddress(DataObject *obj,IOpaqueAddress*& newAddr) {
436
437 // create address for this object
438 MsgStream log(msgSvc(), name());
439
440
441 log << MSG::DEBUG << "RootCnvSvc::createAddress"<<endreq;
442
443 StatusCode status = INVALID_ADDRESS;
444 IRegistry* ent = obj->registry();
445
446 if ( 0 != ent ) {
447 SmartIF<IDataManagerSvc> iaddrReg(dataProvider());
448 std::string path = ent->identifier();
449 LeafMap::iterator itm = m_leaves.find(path);
450
451
452 if ( itm != m_leaves.end() ) {
453 Leaf* leaf = (*itm).second;
454 if ( 0 != leaf ) {
455 std::string spars[3] ;
456 spars[0]=path;
457 spars[1]=leaf->treename;
458 spars[2]=leaf->branchname;
459
460
461 unsigned long ipars[2] ={0,0};
462 if (m_evtsel) ipars[0]=m_evtsel->getRecId();
463
464 status=addressCreator()->createAddress(ROOT_StorageType,leaf->clid,spars,ipars,newAddr);
465 if ( status.isSuccess() ) {
466 status = iaddrReg->registerAddress((IRegistry*)0,path, newAddr);
467 if ( !status.isSuccess() ) {
468 newAddr->release();
469 }
470 }
471 return StatusCode::SUCCESS;
472 }
473 }
474 }
475 return status;
476 }
477
478 StatusCode RootCnvSvc::createAddress(std::string path,IOpaqueAddress*& newAddr) {
479
480 // create address for this object
481 MsgStream log(msgSvc(), name());
482
483 StatusCode status;
484 LeafMap::iterator itm = m_leaves.find(path);
485 SmartIF<IDataManagerSvc> iaddrReg(dataProvider());
486 if ( itm != m_leaves.end() ) {
487 Leaf* leaf = (*itm).second;
488 if ( 0 != leaf ) {
489 std::string spars[3] ;
490 spars[0]=path;
491 spars[1]=leaf->treename;
492 spars[2]=leaf->branchname;
493
494 unsigned long ipars[2] = {0,0};
495 if (m_evtsel) ipars[0]=m_evtsel->getRecId();
496 status=addressCreator()->createAddress(ROOT_StorageType,leaf->clid,spars,ipars,newAddr);
497 if ( status.isSuccess() ) {
498 status = iaddrReg->registerAddress((IRegistry*)0,path, newAddr);
499 if ( !status.isSuccess() ) {
500 newAddr->release();
501 }
502 }
503 return StatusCode::SUCCESS;
504 }
505 }
506
507
508 return StatusCode::FAILURE;
509 }
510
511
512 /// Add converters to the service
513 StatusCode RootCnvSvc::addConverters () {
514 MsgStream log(msgSvc(), name());
515 declareObject(Leaf(EventModel::Dst::DstMdcDedxCol, MdcDedxCnv::classID(), "Event", "m_mdcDedxCol"));
517 declareObject(Leaf(EventModel::Digi::EmcDigiCol, EmcDigiCnv::classID(), "Event", "m_emcDigiCol"));
518 declareObject(Leaf(EventModel::MC::EmcMcHitCol, EmcMcHitCnv::classID(), "Event", "m_emcMcHitCol"));
519 declareObject(Leaf(EventModel::Dst::DstEmcShowerCol, EmcTrackCnv::classID(), "Event", "m_emcTrackCol"));
520
521 declareObject(Leaf("/Event", EventCnv::classID(), "", ""));
522 declareObject(Leaf(EventModel::EventHeader, EvtHeaderCnv::classID(), "Event", "m_runId:m_eventId:m_time:m_eventTag:m_flag1:m_flag2"));
523 declareObject(Leaf(EventModel::Navigator, EvtNavigatorCnv::classID(), "Event", "m_mcMdcMcHits:m_mcMdcTracks:m_mcEmcMcHits:m_mcEmcRecShowers"));
524 declareObject(Leaf(EventModel::Dst::DstExtTrackCol, ExtTrackCnv::classID(), "Event", "m_extTrackCol"));
526 declareObject(Leaf(EventModel::MC::McParticleCol, McParticleCnv::classID(), "Event", "m_mcParticleCol"));
527 declareObject(Leaf(EventModel::Digi::MdcDigiCol, MdcDigiCnv::classID(), "Event", "m_mdcDigiCol"));
528 declareObject(Leaf(EventModel::Dst::DstMdcKalTrackCol, MdcKalTrackCnv::classID(), "Event", "m_mdcKalTrackCol"));
529 declareObject(Leaf(EventModel::MC::MdcMcHitCol, MdcMcHitCnv::classID(), "Event", "m_mdcMcHitCol"));
530 declareObject(Leaf(EventModel::Dst::DstMdcTrackCol, MdcTrackCnv::classID(), "Event", "m_mdcTrackCol"));
531 declareObject(Leaf(EventModel::Digi::MucDigiCol, MucDigiCnv::classID(), "Event", "m_mucDigiCol"));
532 declareObject(Leaf(EventModel::MC::MucMcHitCol, MucMcHitCnv::classID(), "Event", "m_mucMcHitCol"));
533 declareObject(Leaf(EventModel::Dst::DstMucTrackCol, MucTrackCnv::classID(), "Event", "m_mucTrackCol"));
534 declareObject(Leaf(EventModel::Digi::Event, DigiCnv::classID(), "Event", "m_fromMc"));
535 declareObject(Leaf(EventModel::Digi::TofDigiCol, TofDigiCnv::classID(), "Event", "m_tofDigiCol"));
536 declareObject(Leaf(EventModel::MC::TofMcHitCol, TofMcHitCnv::classID(), "Event", "m_tofMcHitCol"));
537 declareObject(Leaf(EventModel::Dst::DstTofTrackCol, TofTrackCnv::classID(), "Event", "m_tofTrackCol"));
538 //declareObject(Leaf("/Event/Digi/LumiDigiCol", LumiDigiCnv::classID(), "Event", "m_lumiDigiCol"));
539 declareObject(Leaf(EventModel::Digi::LumiDigiCol, LumiDigiCnv::classID(), "Event", "m_lumiDigiCol"));
540
542 declareObject(Leaf(EventModel::Trig::TrigData, TrigDataCnv::classID(), "Event", "m_trigData"));
543
545 declareObject(Leaf(EventModel::Hlt::HltRawCol, HltRawCnv::classID(), "Event", "m_hltRawCol"));
546 declareObject(Leaf(EventModel::Hlt::HltInf, HltInfCnv::classID(), "Event", "m_hltInf"));
547 declareObject(Leaf(EventModel::Hlt::DstHltInf, DstHltInfCnv::classID(), "Event", "m_dstHltInf"));
548
550
551 declareObject(Leaf(EventModel::Recon::RecMdcTrackCol, RecMdcTrackCnv::classID(), "Event", "m_recMdcTrackCol"));
552 declareObject(Leaf(EventModel::Recon::RecMdcHitCol, RecMdcHitCnv::classID(), "Event", "m_recMdcHitCol"));
555 declareObject(Leaf(EventModel::Recon::RecMdcDedxCol, RecMdcDedxCnv::classID(),"Event", "m_recMdcDedxCol"));
557
558 declareObject(Leaf(EventModel::Recon::RecEsTimeCol, RecEvTimeCnv::classID(),"Event", "m_recEvTimeCol"));
559 declareObject(Leaf(EventModel::Recon::RecTofTrackCol, RecTofTrackCnv::classID(), "Event", "m_recTofTrackCol"));
560 declareObject(Leaf(EventModel::Recon::RecBTofCalHitCol, RecBTofCalHitCnv::classID(), "Event", "m_recBTofCalHitCol"));
561 declareObject(Leaf(EventModel::Recon::RecETofCalHitCol, RecETofCalHitCnv::classID(), "Event", "m_recETofCalHitCol"));
562 declareObject(Leaf(EventModel::Recon::RecEmcHitCol, RecEmcHitCnv::classID(), "Event", "m_recEmcHitCol"));
563 declareObject(Leaf(EventModel::Recon::RecEmcClusterCol, RecEmcClusterCnv::classID(), "Event", "m_recEmcClusterCol"));
564 declareObject(Leaf(EventModel::Recon::RecEmcShowerCol, RecEmcShowerCnv::classID(), "Event", "m_recEmcShowerCol"));
565 declareObject(Leaf(EventModel::Recon::RecMucTrackCol, RecMucTrackCnv::classID(), "Event", "m_recMucTrackCol"));
567 declareObject(Leaf(EventModel::Recon::RecExtTrackCol, RecExtTrackCnv::classID(),"Event", "m_recExtTrackCol"));
568 declareObject(Leaf(EventModel::Recon::RecZddChannelCol, RecZddChannelCnv::classID(), "Event", "m_recZddChannelCol"));
571 declareObject(Leaf(EventModel::EvtRec::EvtRecTrackCol, EvtRecTrackCnv::classID(), "Event", "m_evtRecTrackCol"));
573 declareObject(Leaf(EventModel::EvtRec::EvtRecVeeVertexCol, EvtRecVeeVertexCnv::classID(), "Event", "m_evtRecVeeVertexCol"));
574 declareObject(Leaf(EventModel::EvtRec::EvtRecPi0Col, EvtRecPi0Cnv::classID(), "Event", "m_evtRecPi0Col"));
575 declareObject(Leaf(EventModel::EvtRec::EvtRecEtaToGGCol, EvtRecEtaToGGCnv::classID(), "Event", "m_evtRecEtaToGGCol"));
576 declareObject(Leaf(EventModel::EvtRec::EvtRecDTagCol, EvtRecDTagCnv::classID(), "Event", "m_evtRecDTagCol"));
577
578 return StatusCode::SUCCESS;
579
580 }
const long int ROOT_StorageType
*******INTEGER m_nBinMax INTEGER m_NdiMax !No of bins in histogram for cell exploration division $ !Last vertex $ !Last active cell $ !Last cell in buffer $ !No of sampling when dividing cell $ !No of function total $ !Flag for random ceel for $ !Flag for type of for WtMax $ !Flag which decides whether vertices are included in the sampling $ entire domain is hyp !Maximum effective eevents per saves r n generator level $ !Flag for chat level in output
Definition: FoamA.h:89
XmlRpcServer s
Definition: HelloServer.cpp:11
const InterfaceID IID_IRootCnvSvc
static TDigiEvent * getWriteObject()
returns object to be written (maintained here for all DIGI-converters)
static TDstEvent * getWriteObject()
returns object to be written (maintained here for all DIGI-converters)
static TEvtHeader * getWriteObject()
returns object to be written (maintained here for all DIGI-converters)
static TEvtNavigator * getWriteObject()
returns object to be written (maintained here for all DIGI-converters)
static THltEvent * getWriteObject()
returns object to be written (maintained here for all DIGI-converters)
static TMcEvent * getWriteObject()
returns object to be written (maintained here for all DIGI-converters)
static TRecTrackEvent * getWriteObject()
returns object to be written (maintained here for all DIGI-converters)
Definition of a Root address, derived from IOpaqueAddress.
object regrouping CLID and pathname with treename/branchname
Root Event Conversion Service which coordinates all of our converters.
virtual StatusCode createAddress(long int svc_type, const CLID &clid, const std::string *par, const unsigned long *ip, IOpaqueAddress *&refpAddress)
create address containing ROOT treename, branchname, entry number
Definition: RootCnvSvc.cxx:372
virtual StatusCode initialize()
Definition: RootCnvSvc.cxx:143
virtual StatusCode updateServiceState(IOpaqueAddress *pAddress)
Update state of the service.
Definition: RootCnvSvc.cxx:312
virtual StatusCode commitOutput(const std::string &output, bool do_commit)
Commit pending output (fill the TTrees).
Definition: RootCnvSvc.cxx:397
RootCnvSvc(const std::string &name, ISvcLocator *svc)
Definition: RootCnvSvc.cxx:100
virtual StatusCode declareObject(const Leaf &leaf)
Associates a path on TDS with a particular converter.
Definition: RootCnvSvc.cxx:297
virtual StatusCode finalize()
Definition: RootCnvSvc.cxx:198
virtual StatusCode queryInterface(const InterfaceID &riid, void **ppvInterface)
Override inherited queryInterface due to enhanced interface.
Definition: RootCnvSvc.cxx:359
virtual StatusCode finalize()
virtual void setTagInputFile(std::vector< std::string > input)
virtual StatusCode addInput(const std::string &treename, const std::string &file)
add input tree to the list
static RootInterface * Instance(MsgStream log)
singleton behaviour
virtual StatusCode addOutput(const std::string &treename, const std::string &file, int splitx, int bufsize, int compression)
add output tree to the list
virtual StatusCode fillTrees()
fill in all trees
void Clear(Option_t *option="")
Definition: TDigiEvent.cxx:83
void Clear(Option_t *option="")
Definition: TDstEvent.cxx:108
void Clear(Option_t *option="")
Definition: TEvtHeader.cxx:30
void Clear(Option_t *option="")
void Clear(Option_t *option="")
void Clear(Option_t *option="")
Definition: THltEvent.cxx:55
void Clear(Option_t *option="")
Definition: TMcEvent.cxx:93
void Clear(Option_t *option="")
void Clear(Option_t *option="")
Definition: TTrigEvent.cxx:35
static TTrigEvent * getWriteObject()
returns object to be written (maintained here for all DIGI-converters)
void clear()
Definition: commonData.cxx:150
static int expandEnvVar(std::string *toExpand, const std::string &openDel=std::string("$("), const std::string &closeDel=std::string(")"))
static int catchOptionVal(std::string *toCatch, const int ops=0, const std::string &openDel=std::string("#("), const std::string &closeDel=std::string(")"))