ATLAS Offline Software
DetailedTrackTruthCnv_p3.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 // T/P converter for DetailedTrackTruth.
6 // Andrei Gaponenko <agaponenko@lbl.gov>, 2008
7 // Olivier.Arnaez@cern.ch, 2015
8 
12 
15 
17 
18 namespace {
19  const SubDetHitStatisticsCnv_p0 subDetHitStatConverter;
20  const TruthTrajectoryCnv_p2 truthTrajConverter;
21 }
22 
23 
25  DetailedTrackTruth* trans,
26  MsgStream& msg ) const
27 {
28  msg<<MSG::DEBUG<<"DetailedTrackTruthCnv_p3::persToTrans()"<<endmsg;
29 
30  subDetHitStatConverter.persToTrans(&pers->m_hitsCommon, &TrackTruthCollectionAccessor::statsCommon(trans), msg);
31  subDetHitStatConverter.persToTrans(&pers->m_hitsTrack, &TrackTruthCollectionAccessor::statsTrack(trans), msg);
32  subDetHitStatConverter.persToTrans(&pers->m_hitsTruth, &TrackTruthCollectionAccessor::statsTruth(trans), msg);
33  truthTrajConverter.persToTrans(&pers->m_trajectory, &TrackTruthCollectionAccessor::trajectory(trans), msg);
34 
35  msg<<MSG::DEBUG<<"DetailedTrackTruthCnv_p3::persToTrans() DONE"<<endmsg;
36 }
37 
40  MsgStream& msg ) const
41 {
42  msg<<MSG::DEBUG<<"DetailedTrackTruthCnv_p3::transToPers()"<<endmsg;
43 
44  subDetHitStatConverter.transToPers(&trans->statsCommon(), &pers->m_hitsCommon, msg);
45  subDetHitStatConverter.transToPers(&trans->statsTrack(), &pers->m_hitsTrack, msg);
46  subDetHitStatConverter.transToPers(&trans->statsTruth(), &pers->m_hitsTruth, msg);
47  truthTrajConverter.transToPers(&trans->trajectory(), &pers->m_trajectory, msg);
48 
49  msg<<MSG::DEBUG<<"DetailedTrackTruthCnv_p3::transToPers() DONE"<<endmsg;
50 }
TrackTruthCollectionAccessor::statsCommon
static SubDetHitStatistics & statsCommon(DetailedTrackTruth *dt)
Definition: TrackTruthCollectionAccessor.h:42
Trk::DetailedTrackTruth_p3::m_trajectory
TruthTrajectory_p2 m_trajectory
Definition: DetailedTrackTruth_p3.h:26
TrackTruthCollectionAccessor::statsTrack
static SubDetHitStatistics & statsTrack(DetailedTrackTruth *dt)
Definition: TrackTruthCollectionAccessor.h:43
DetailedTrackTruth::statsTruth
const SubDetHitStatistics & statsTruth() const
Definition: DetailedTrackTruth.h:21
SubDetHitStatisticsCnv_p0
Definition: SubDetHitStatisticsCnv_p0.h:25
DetailedTrackTruth::statsCommon
const SubDetHitStatistics & statsCommon() const
Definition: DetailedTrackTruth.h:19
TruthTrajectoryCnv_p2.h
DetailedTrackTruthCnv_p3::transToPers
virtual void transToPers(const DetailedTrackTruth *transObj, Trk::DetailedTrackTruth_p3 *persObj, MsgStream &msg) const override
Method creating the persistent representation DetailedTrackTruth_p3 from its transient representation...
Definition: DetailedTrackTruthCnv_p3.cxx:38
Trk::DetailedTrackTruth_p3::m_hitsCommon
SubDetHitStatistics_p0 m_hitsCommon
Definition: DetailedTrackTruth_p3.h:23
Trk::DetailedTrackTruth_p3::m_hitsTrack
SubDetHitStatistics_p0 m_hitsTrack
Definition: DetailedTrackTruth_p3.h:24
DetailedTrackTruthCnv_p3::persToTrans
virtual void persToTrans(const Trk::DetailedTrackTruth_p3 *persObj, DetailedTrackTruth *transObj, MsgStream &msg) const override
Method creating the transient representation of Analysis::DetailedTrackTruth from its persistent repr...
Definition: DetailedTrackTruthCnv_p3.cxx:24
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
DetailedTrackTruth_p3.h
Trk::DetailedTrackTruth_p3::m_hitsTruth
SubDetHitStatistics_p0 m_hitsTruth
Definition: DetailedTrackTruth_p3.h:25
DetailedTrackTruth::statsTrack
const SubDetHitStatistics & statsTrack() const
Definition: DetailedTrackTruth.h:20
DetailedTrackTruth.h
SubDetHitStatisticsCnv_p0.h
DetailedTrackTruth
Definition: DetailedTrackTruth.h:16
TrackTruthCollectionAccessor::statsTruth
static SubDetHitStatistics & statsTruth(DetailedTrackTruth *dt)
Definition: TrackTruthCollectionAccessor.h:44
TrackTruthCollectionAccessor::trajectory
static TruthTrajectory & trajectory(DetailedTrackTruth *dt)
Definition: TrackTruthCollectionAccessor.h:45
DetailedTrackTruthCnv_p3.h
TruthTrajectoryCnv_p2
Definition: TruthTrajectoryCnv_p2.h:26
TrackTruthCollectionAccessor.h
DEBUG
#define DEBUG
Definition: page_access.h:11
DetailedTrackTruth::trajectory
const TruthTrajectory & trajectory() const
Definition: DetailedTrackTruth.h:18
python.AutoConfigFlags.msg
msg
Definition: AutoConfigFlags.py:7
Trk::DetailedTrackTruth_p3
Definition: DetailedTrackTruth_p3.h:21