ATLAS Offline Software
Loading...
Searching...
No Matches
LUCID_RawDataContainerCnv.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3*/
4
6
8
9 MsgStream mlog(msgSvc(), "LUCID_RawDataContainerCnv");
10
11 mlog << MSG::DEBUG << "In LUCID_RawDataContainerCnv::createPersistent " << endmsg;
12
14 LUCID_RawDataContainer_PERS* persObj = converter.createPersistent(transCont, mlog);
15
16 return persObj;
17}
18
20
21 MsgStream mlog(msgSvc(), "LUCID_RawDataContainer");
22
23 mlog << MSG::DEBUG << "In LUCID_RawDataContainerCnv::createTransient " << endmsg;
24
26
27 LUCID_RawDataContainer* trans_cont(nullptr);
28
29 static const pool::Guid p0_guid("0C023583-E3D4-4C7D-9B20-B6B2A1018D2F");
30 static const pool::Guid p1_guid("88937AAE-D299-4A80-8608-96EFB3068F9A");
31
32 if (this->compareClassGuid(p0_guid)) { // Before T/P separation
33 trans_cont = this->poolReadObject<LUCID_RawDataContainer>();
34 }
35 else if (this->compareClassGuid(p1_guid)) { // First persistent version
36
37 std::unique_ptr< LUCID_RawDataContainer_p1 > col_vect( this->poolReadObject< LUCID_RawDataContainer_p1 >());
38
39 trans_cont = converter_p1.createTransient(col_vect.get(), mlog);
40 }
41 else {
42 throw std::runtime_error("Unsupported persistent version of Data container");
43 }
44
45 return trans_cont;
46}
47
48
49
#define endmsg
LUCID_RawDataContainer_p1 LUCID_RawDataContainer_PERS
virtual LUCID_RawDataContainer_PERS * createPersistent(LUCID_RawDataContainer *transCont)
virtual LUCID_RawDataContainer * createTransient()
virtual PERS * createPersistent(const TRANS *transObj, MsgStream &log)
Create persistent representation of a transient object.
virtual TRANS * createTransient(const PERS *persObj, MsgStream &log)
Create transient representation of a persistent object.