ATLAS Offline Software
TrigVertexCountsCollectionCnv.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3 */
4 
7 
11 {}
12 
14 {
15  delete m_TPConverter;
16 }
17 
18 
19 //createPersistent
21 {
22  MsgStream mlog(msgSvc(), "TrigVertexCountsCollectionConverter" );
23 
24  mlog << MSG::DEBUG << "TrigVertexCountsCollectionCnv::createPersistent" << endmsg;
25 
27 
28  return persObj;
29 
30 }//end of create persistent method
31 
32 
33 //createTransient
35 {
36  MsgStream mlog(msgSvc(), "TrigVertexCountsCollectionConverter" );
37 
38  mlog << MSG::DEBUG << "TrigVertexCountsCollectionCnv::createTransient" << endmsg;
39 
40  static const pool::Guid tlp1_guid( "2A1D4A4E-D566-4C71-B051-D5D79A856753" );
41  static const pool::Guid p1_guid( "232B47D0-65CA-4883-AC51-0D76EAEA3194" );
42  static const pool::Guid trans_guid( "7A4412AD-C11D-4EFD-AE15-D343D2CB28BC" );
43 
44 
45  TrigVertexCountsCollection *p_container = 0;
46 
47  if(compareClassGuid(tlp1_guid)) {
48  poolReadObject<TrigVertexCountsCollection_PERS>(*m_TPConverter);
49  p_container = m_TPConverter->createTransient(mlog);
50  }
51  else if(compareClassGuid(p1_guid)) {
52  std::unique_ptr< TrigVertexCountsCollection_p1 > col_vect( poolReadObject< TrigVertexCountsCollection_p1 >() );
54  p_container = converter.createTransient( col_vect.get(), mlog );
55  }
56  else if(compareClassGuid(trans_guid)) {
57  p_container = poolReadObject<TrigVertexCountsCollection>();
58  }
59  else {
60  throw std::runtime_error( "Unsupported persistent version of TrigVertexCountsCollection" );
61  }
62 
63  return p_container;
64 
65 }//end of create transient method
66 
TrigVertexCountsCollectionCnv::createPersistent
virtual TrigVertexCountsCollection_PERS * createPersistent(TrigVertexCountsCollection *transObj)
Definition: TrigVertexCountsCollectionCnv.cxx:20
TrigVertexCountsCollectionCnv::~TrigVertexCountsCollectionCnv
~TrigVertexCountsCollectionCnv()
Definition: TrigVertexCountsCollectionCnv.cxx:13
TPPolyCnvBase::createTransient
virtual TRANS * createTransient(const PERS *persObj, MsgStream &log)
Create transient representation of a persistent object.
CSV_InDetExporter.new
new
Definition: CSV_InDetExporter.py:145
TrigVertexCountsCollectionCnv::createTransient
virtual TrigVertexCountsCollection * createTransient()
Definition: TrigVertexCountsCollectionCnv.cxx:34
pool::Guid
::Guid Guid
Definition: T_AthenaPoolCustCnv.h:19
TrigVertexCountsCollectionCnv_tlp1.h
TopLevelTPConverter::createTransient
TRANS * createTransient(MsgStream &log)
Create transient representation of the persistent object known to this converter.
Definition: TopLevelTPConverter.h:62
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
TrigVertexCountsCollectionCnv::TrigVertexCountsCollectionCnv
TrigVertexCountsCollectionCnv(ISvcLocator *svcloc)
Definition: TrigVertexCountsCollectionCnv.cxx:8
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
TrigVertexCountsCollectionCnv_tlp1
Definition: TrigVertexCountsCollectionCnv_tlp1.h:26
TrigVertexCountsCollection_tlp1
Definition: TrigVertexCountsCollection_tlp1.h:22
TrigVertexCountsCollectionCnv.h
TrigVertexCountsCollectionCnv_p1
Definition: TrigVertexCountsCollectionCnv_p1.h:25
TrigVertexCountsCollection
Definition: TrigVertexCountsCollection.h: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
T_AthenaPoolCustCnv::compareClassGuid
virtual bool compareClassGuid(const Guid &clid) const
Compare POOL class GUID with the one of the object being read.
TrigVertexCountsCollectionCnv::m_TPConverter
TrigVertexCountsCollectionCnv_tlp1 * m_TPConverter
Definition: TrigVertexCountsCollectionCnv.h:50