ATLAS Offline Software
TrigMuonEFIsolationContainerCnv.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
8 
9 
12 {
13 
14 }
15 
16 
17 
20  MsgStream mlog(msgSvc(), "TrigMuonEFIsolationContainerConverter" );
21  mlog << MSG::DEBUG << "TrigMuonEFIsolationContainerCnv::createPersistent" << endmsg;
22 
23  TrigMuonEFIsolationContainer_PERS *persObj = m_converter_p2.createPersistent(transCont, mlog);
24 
25  return persObj;
26 }
27 
30 
31  MsgStream mlog(msgSvc(), "TrigMuonEFIsolationContainerConverter" );
32  mlog << MSG::DEBUG << "TrigMuonEFIsolationContainerCnv::createTransient" << endmsg;
33 
34  static const pool::Guid p1_guid("5C3ECE20-F26F-4811-BA76-B2DC567858BC");
35  static const pool::Guid p2_guid("B24570F4-BB65-4D5C-A8E2-C44E36E7B0B5");
36 
37  TrigMuonEFIsolationContainer* trans_cont(0);
38 
39  if ( compareClassGuid(p2_guid) ) {
40  std::unique_ptr< TrigMuonEFIsolationContainer_p2 > col_vect( this->poolReadObject< TrigMuonEFIsolationContainer_p2 >() );
41  trans_cont = m_converter_p2.createTransient( col_vect.get(), mlog );
42  } else if ( compareClassGuid(p1_guid) ) {
43  std::unique_ptr< TrigMuonEFIsolationContainer_p1 > col_vect( this->poolReadObject< TrigMuonEFIsolationContainer_p1 >() );
44  trans_cont = m_converter_p1.createTransient( col_vect.get(), mlog );
45  } else {
46 
47  throw std::runtime_error("Unsupported persistent version of Data container");
48 
49  }
50  return trans_cont;
51 
52 }
TrigMuonEFIsolationContainer_p2
Persistent class partner for TrigMuonEFIsolationContainer.
Definition: TrigMuonEFIsolationContainer_p2.h:22
TrigMuonEFIsolationContainer_p2.h
TrigMuonEFIsolationContainer_p1.h
TrigMuonEFIsolationContainerCnv::TrigMuonEFIsolationContainerCnv
TrigMuonEFIsolationContainerCnv(ISvcLocator *svcloc)
Definition: TrigMuonEFIsolationContainerCnv.cxx:10
TrigMuonEFIsolationContainerCnv.h
pool::Guid
::Guid Guid
Definition: T_AthenaPoolCustCnv.h:19
TrigMuonEFIsolationContainerCnv::m_converter_p1
TrigMuonEFIsolationContainerCnv_p1 m_converter_p1
Definition: TrigMuonEFIsolationContainerCnv.h:44
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
TrigMuonEFIsolationContainerCnv::createTransient
TrigMuonEFIsolationContainer * createTransient()
create transient
Definition: TrigMuonEFIsolationContainerCnv.cxx:29
TrigMuonEFIsolationContainerCnv::m_converter_p2
TrigMuonEFIsolationContainerCnv_p2 m_converter_p2
Definition: TrigMuonEFIsolationContainerCnv.h:45
TrigMuonEFIsolationContainerCnv::createPersistent
TrigMuonEFIsolationContainer_PERS * createPersistent(TrigMuonEFIsolationContainer *transCont)
create persistent
Definition: TrigMuonEFIsolationContainerCnv.cxx:19
TrigMuonEFIsolationContainer
Definition: TrigMuonEFIsolationContainer.h:25
DEBUG
#define DEBUG
Definition: page_access.h:11
T_AthenaPoolCustCnv::compareClassGuid
virtual bool compareClassGuid(const Guid &clid) const
Compare POOL class GUID with the one of the object being read.