ATLAS Offline Software
Loading...
Searching...
No Matches
EventBookkeeperCnv_p2.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3*/
4
6// Implementation file for class EventBookkeeperCnv_p2
7// Author: David Cote, July 2009 <david.cote@cern.ch>
9
12
16 pers->m_cycle = trans->getCycle();
17 pers->m_name = trans->getName();
18 pers->m_description = trans->getDescription();
19 pers->m_inputstream = trans->getInputStream();
20 pers->m_outputstream = trans->getOutputStream();
21 pers->m_logic = trans->getLogic();
22 //To fill children, create new EventBookkeeper_p2 and call transToPers iteratively
23 for(unsigned int i=0; i<trans->getChildrenEventBookkeepers()->size(); i++){
24 const EventBookkeeper* tmpTrans=trans->getChildrenEventBookkeepers()->at(i);
26 transToPers(tmpTrans,tmpPers,log);
27 if (!pers->m_childrenEB){ pers->m_childrenEB = new std::vector<EventBookkeeper_p2*>; }
28 pers->m_childrenEB->push_back(tmpPers);
29 }
30 return;
31}
32
36 trans->setCycle( pers->m_cycle );
37 trans->setName( pers->m_name );
38 trans->setDescription( pers->m_description );
39 trans->setInputStream( pers->m_inputstream );
40 trans->setOutputStream(pers->m_outputstream);
41 trans->setLogic(pers->m_logic);
42 //To fill children, create new EventBookkeeper and call persToTrans iteratively
43 if (pers->m_childrenEB) {
44 for(unsigned int i=0; i<pers->m_childrenEB->size(); i++){
45 const EventBookkeeper_p2* tmpPers=pers->m_childrenEB->at(i);
46 EventBookkeeper* tmpTrans=new EventBookkeeper();
47 persToTrans(tmpPers,tmpTrans,log);
48 trans->AddChild(tmpTrans);
49 }
50 }
51 return;
52}
virtual void persToTrans(const EventBookkeeper_p2 *persObj, EventBookkeeper *transObj, MsgStream &log)
virtual void transToPers(const EventBookkeeper *transObj, EventBookkeeper_p2 *persObj, MsgStream &log)
std::vector< EventBookkeeper_p2 * > * m_childrenEB
unsigned long long m_nAcceptedEvents
uint64_t getNAcceptedEvents() const
const std::string & getDescription() const
const std::string & getLogic() const
const std::string & getInputStream() const
const std::string & getOutputStream() const
void setNAcceptedEvents(uint64_t nEvents)
double getNWeightedAcceptedEvents() const
void setDescription(const std::string &description)
const std::vector< EventBookkeeper * > * getChildrenEventBookkeepers() const
void setCycle(int cycle)
const std::string & getName() const
void setOutputStream(const std::string &outputstream)
void setNWeightedAcceptedEvents(double nWeightedEvents)
void setName(const std::string &name)
void AddChild(EventBookkeeper *eb)
int getCycle() const
void setLogic(const std::string &logic)
void setInputStream(const std::string &inputstream)