ATLAS Offline Software
Loading...
Searching...
No Matches
TileHitVectorCnv_p1.cxx
Go to the documentation of this file.
1
2
3/*
4 Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
5*/
6
7// TileHitVectorCnv_p1.cxx
8// Implementation file for class TileHitVectorCnv_p1
9// Author: Alexander Solodkov <Sanya.Solodkov@cern.ch>
10// Date: June 2009
12
14
16
17 const TileHitVector_p1::HitVector& pvec = persObj->getVector();
18
19 // the only reason why we reimplement this method is that we want to be sure
20 // that correct size is reserved for the vector directly in the constructor
21 TileHitVector* trans = new TileHitVector(persObj->name(), pvec.size());
22 trans->resize(pvec.size());
23
24 // since we reimplement this method anyhow, let's call directly persToTrans method of
25 // the converter instead of doing this through few calls in base class
26 TileHitCnv_p1 element_cnv;
29
30 for (it = trans->begin(), ip = pvec.begin(); ip != pvec.end(); ++ip, ++it) {
31 element_cnv.persToTrans( &*ip, &*it, log );
32 }
33
34
35 return trans;
36}
std::array< fp_t, 2 > pvec
AtlasHitsVector< TileHit > TileHitVector
const_iterator begin() const
void resize(size_type n)
virtual void persToTrans(const TileHit_p1 *persObj, TileHit *transObj, MsgStream &log) const override
virtual TileHitVector * createTransient(const TileHitVector_p1 *persObj, MsgStream &log)
Create transient representation of a persistent object.
std::vector< TileHit_p1 > HitVector
typedefs
const HitVector & getVector() const
HitVector::const_iterator const_iterator
const std::string & name() const