ATLAS Offline Software
Loading...
Searching...
No Matches
LArPedestalMCCnv.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3*/
4
10
12#include "LArPedestalMCCnv.h"
14
16
19{
20 MsgStream log(msgSvc(), "LArPedestalMCCnv" );
21 //log << MSG::DEBUG << "LArPedestalMC write" << endmsg;
22 LArPedestalMCPersType* persObj = TPconverter.createPersistentConst( transObj, log );
23 //log << MSG::DEBUG << "Success" << endmsg;
24 return persObj;
25}
26
29{
30 static const pool::Guid p1_guid("3891D5E0-82D1-45AB-97B1-CE4CF25D6E16");
31 static const pool::Guid p0_guid("C147EFC8-5283-4DAE-AD20-0E2CB79E54B6");
32 if( compareClassGuid(p1_guid) ) {
33 // using unique_ptr ensures deletion of the persistent object
34 std::unique_ptr< LArPedestalMC_p1 > col_vect( poolReadObject< LArPedestalMC_p1 >() );
35 MsgStream log(msgSvc(), "LArPedestalMCCnv" );
36 //log << MSG::INFO << "Reading LArPedestalMC_p1" << endmsg;
37 return TPconverter.createTransientConst( col_vect.get(), log );
38 }
39 else if( compareClassGuid(p0_guid) ) {
40 // subset from before TP separation
41
42 MsgStream log(msgSvc(), "LArPedestalMCCnv" );
43 log << MSG::INFO << "Reading LArPedestalMC (original)" << endmsg;
44
46
47 return (peds);
48
49 }
50 throw std::runtime_error("Unsupported persistent version of LArPedestalMCCnv");
51}
52
53
54
#define endmsg
static const LArAutoCorrSubsetCnv_p1 TPconverter
AthenaPool converter LArPedestalMC.
LArPedestalMC_p1 LArPedestalMCPersType
LArPedestalMC LArPedestalMCTransType
virtual LArPedestalMCPersType * createPersistent(LArPedestalMCTransType *transObj)
virtual LArPedestalMCTransType * createTransient()
persistent class container of LArConditionsMC for LArPedestal data.
Implementation of the interface ILArfSampl for MC: only one constant is needed for MC.