ATLAS Offline Software
Loading...
Searching...
No Matches
RpcCoinDataContainerCnv.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3*/
4
6
7// Gaudi
8#include "GaudiKernel/StatusCode.h"
9#include "GaudiKernel/MsgStream.h"
10
11// Athena
13
14// Id includes
16
20
22
24 // Call base clase initialize
26 return StatusCode::FAILURE;
27
28 //msgSvc()->setOutputLevel( "RpcCoinDataContainerCnv", MSG::INFO );
29
30 // Get the messaging service, print where you are
31 MsgStream log(msgSvc(), "RpcCoinDataContainerCnv");
32 if (log.level() <= MSG::DEBUG) log << MSG::INFO << "RpcCoinDataContainerCnv::initialize()" << endmsg;
33
34 return StatusCode::SUCCESS;
35}
36
38 MsgStream log(msgSvc(), "RpcCoinDataContainerCnv" );
39 if (log.level() <= MSG::DEBUG) log<<MSG::DEBUG<<"createPersistent(): main converter"<<endmsg;
40 Muon::RpcCoinDataContainerCnv_p1::PERS *rpc_p= m_converter_p1.createPersistent( transCont, log );
41 return rpc_p;
42}
43
45 MsgStream log(msgSvc(), "RpcCoinDataContainerCnv" );
46 static const pool::Guid p1_guid("AF0DB103-E825-45E5-9C29-9C32342756DD");
47 if (log.level() <= MSG::DEBUG) log<<MSG::DEBUG<<"createTransient(): main converter"<<endmsg;
48 Muon::RpcCoinDataContainer* p_collection(nullptr);
49 if( compareClassGuid(p1_guid) ) {
50 if (log.level() <= MSG::DEBUG) log<<MSG::DEBUG<<"createTransient(): T/P version 1 detected"<<endmsg;
51 std::unique_ptr< Muon::RpcCoinDataContainerCnv_p1::PERS > col_vect( poolReadObject< Muon::RpcCoinDataContainerCnv_p1::PERS >() );
52 if (log.level() <= MSG::DEBUG) log << MSG::DEBUG << "Delegate TP converter " << endmsg;
53 p_collection = m_converter_p1.createTransient( col_vect.get(), log );
54 } else {
55 throw std::runtime_error("Unsupported persistent version of RpcCoinDataContainer");
56 }
57 return p_collection;
58}
#define endmsg
T_AthenaPoolCustomCnv< Muon::RpcCoinDataContainer, Muon::RpcCoinDataContainerCnv_p1::PERS > RpcCoinDataContainerCnvBase
Muon::MuonPRD_Container_p2< RpcCoinData_p1 > PERS
virtual StatusCode initialize()
Gaudi Service Interface method implementations:
virtual Muon::RpcCoinDataContainer * createTransient()
Muon::RpcCoinDataContainerCnv_p1 m_converter_p1
virtual Muon::RpcCoinDataContainerCnv_p1::PERS * createPersistent(Muon::RpcCoinDataContainer *transCont)
virtual ~RpcCoinDataContainerCnv()
RpcCoinDataContainerCnv(ISvcLocator *svcloc)
MuonCoinDataContainer< RpcCoinDataCollection > RpcCoinDataContainer