|
ATLAS Offline Software
|
Go to the documentation of this file.
37 Base_t::operator=( rhs );
54 msg <<
MSG::DEBUG <<
"Loading McEventCollection from persistent state..."
61 datapool.
evt.reserve ( 20 );
62 datapool.
vtx.reserve ( 1000 );
63 datapool.
part.reserve( 1000 );
69 const std::size_t nEvts = persObj->size();
70 if ( datapool.
evt.capacity() - datapool.
evt.allocated() < nEvts ) {
71 datapool.
evt.reserve( datapool.
evt.allocated() + nEvts );
74 for (
const auto & persEvt : *persObj) {
81 msg <<
MSG::DEBUG <<
"Loaded McEventCollection from persistent state [OK]"
89 msg <<
MSG::DEBUG <<
"Creating persistent state of McEventCollection..."
93 <<
"This transient-to-persistent converter method has been RETIRED !!"
95 <<
"You are not supposed to end-up here ! Go away !"
98 throw std::runtime_error(
"Retired McEventCollectionCnv_p1::transToPers() !!" );
void reserve(size_type n)
Attempt to preallocate enough memory for a specified number of elements.
McEventCollectionCnv_p1()
Default constructor:
@ VIEW_ELEMENTS
this data object is a view, it does not own its elmts
virtual ~McEventCollectionCnv_p1()
Destructor.
virtual void transToPers(const McEventCollection *transObj, McEventCollection_p1 *persObj, MsgStream &msg)
Method creating the persistent representation McEventCollection_p1 from its transient representation ...
GenEvtPool_t evt
an arena of HepMC::GenEvent for efficient object instantiation
virtual void persToTrans(const McEventCollection_p1 *persObj, McEventCollection *transObj, MsgStream &msg)
Method creating the transient representation of McEventCollection from its persistent representation ...
GenVtxPool_t vtx
an arena of HepMC::GenVertex for efficient object instantiation
This defines the McEventCollection, which is really just an ObjectVector of McEvent objects.
void clear()
Erase all the elements in the collection.
void setDataPool(HepMC::DataPool *pool)
reset the @ HepMC::DataPool pointer
virtual void persToTrans(const GenEvent_p1 *persObj, HepMC::GenEvent *transObj, MsgStream &msg)
Destructor:
value_type push_back(value_type pElem)
Add an element to the end of the collection.
McEventCollectionCnv_p1 & operator=(const McEventCollectionCnv_p1 &rhs)
Assignement operator.
HepMC::GenEvent * getGenEvent()
GenPartPool_t part
an arena of HepMC::GenParticle for efficient object instantiation