ATLAS Offline Software
TrigEventAthenaPool/src/TrigTauTracksInfo.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #include "TrigTauTracksInfoCnv.h"
8 
11  m_TPConverter (new TrigTauTracksInfoCnv_tlp1)
12 {}
14 {
15  delete m_TPConverter;
16 }
17 
18 //create persistent
20 {
21  MsgStream mlog(msgSvc(), "TrigTauTracksInfoConverter" );
22  mlog << MSG::DEBUG << "TrigTauTracksInfoCnv::createPersistent" << endmsg;
23 
25 
26  return persObj;
27 }
28 
29 //create transient
31 {
32  MsgStream mlog(msgSvc(), "TrigTauTracksInfoConverter" );
33  mlog << MSG::DEBUG << "TrigTauTracksInfoCnv::createTransient " << endmsg;
34 
35  static const pool::Guid tlp1_guid("ABF3C91C-A007-440E-8AEE-753FAA453352");
36  static const pool::Guid p0_guid("630E4944-7EDE-4938-B189-020DBC0436AE");
37 
38  TrigTauTracksInfo *trans_cont(0);
39 
40  if( compareClassGuid(tlp1_guid) ) {
41 
42  mlog << MSG::DEBUG << "TrigTauTracksInfoCnv::reading tlp1 persistent object" << endmsg;
43  std::unique_ptr< TrigTauTracksInfo_tlp1 > col_vect( this->poolReadObject< TrigTauTracksInfo_tlp1 >() );
44  trans_cont = m_TPConverter->createTransient( col_vect.get(), mlog );
45 
46  }
47  else if( compareClassGuid(p0_guid) ) {
48 
49  mlog << MSG::DEBUG << "TrigTauTracksInfoCnv::reading p0 persistent object" << endmsg;
50  // old version from before TP separation, just return it
51  trans_cont = this->poolReadObject<TrigTauTracksInfo>();
52 
53  } else {
54 
55  throw std::runtime_error("Unsupported persistent version of Data container");
56 
57  }
58 
59  return trans_cont;
60 
61 }
TrigTauTracksInfo_tlp1
Definition: TrigTauTracksInfo_tlp1.h:24
TrigTauTracksInfo_tlp1.h
CSV_InDetExporter.new
new
Definition: CSV_InDetExporter.py:145
TrigTauTracksInfoCnv.h
TrigTauTracksInfoCnv::m_TPConverter
TrigTauTracksInfoCnv_tlp1 * m_TPConverter
Definition: TrigTauTracksInfoCnv.h:47
pool::Guid
::Guid Guid
Definition: T_AthenaPoolCustCnv.h:19
TrigTauTracksInfo
Definition: TrigTauTracksInfo.h:28
TopLevelTPConverter::createTransient
TRANS * createTransient(MsgStream &log)
Create transient representation of the persistent object known to this converter.
Definition: TopLevelTPConverter.h:62
TrigTauTracksInfoCnv_tlp1
Definition: TrigTauTracksInfoCnv_tlp1.h:29
python.InDetPriVxFinderConfig.mlog
mlog
Definition: InDetPriVxFinderConfig.py:134
StdJOSetup.msgSvc
msgSvc
Provide convenience handles for various services.
Definition: StdJOSetup.py:36
T_AthenaPoolCustomCnv
Compatibility for old converter classes that don't get passed the key.
Definition: T_AthenaPoolCustomCnv.h:132
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
TrigTauTracksInfoCnv::TrigTauTracksInfoCnv
TrigTauTracksInfoCnv(ISvcLocator *svcloc)
Definition: TrigEventAthenaPool/src/TrigTauTracksInfo.cxx:9
TrigTauTracksInfoCnv::~TrigTauTracksInfoCnv
~TrigTauTracksInfoCnv()
Definition: TrigEventAthenaPool/src/TrigTauTracksInfo.cxx:13
DEBUG
#define DEBUG
Definition: page_access.h:11
TopLevelTPConverter::createPersistent
virtual TL_PERS * createPersistent(const TRANS *transObj, MsgStream &log)
Create persistent representation of transObj.
Definition: TopLevelTPConverter.h:110
TrigTauTracksInfoCnv::createPersistent
TrigTauTracksInfo_PERS * createPersistent(TrigTauTracksInfo *transCont)
Definition: TrigEventAthenaPool/src/TrigTauTracksInfo.cxx:19
T_AthenaPoolCustCnv< TrigTauTracksInfo, TrigTauTracksInfo_PERS >::compareClassGuid
virtual bool compareClassGuid(const Guid &clid) const
Compare POOL class GUID with the one of the object being read.
TrigTauTracksInfoCnv::createTransient
TrigTauTracksInfo * createTransient()
Definition: TrigEventAthenaPool/src/TrigTauTracksInfo.cxx:30
TrigTauTracksInfoCnv_tlp1.h