ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Trigger
TrigT1
TrigT1EventAthenaPool
src
JetElementCollectionCnv.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3
*/
4
10
11
#include "
JetElementCollectionCnv.h
"
12
13
//createPersistent
14
JetElementCollection_PERS
*
JetElementCollectionCnv::createPersistent
(
JetElementCollection
*transObj)
15
{
16
17
MsgStream mlog(msgSvc(),
"JetElementCollectionConverter"
);
18
19
//mlog << MSG::DEBUG << "JetElementCollectionCnv::createPersistent called" << endmsg;
20
21
JetElementCollection_PERS
* p_TTColl =
m_TPConverter_tlp1
.createPersistent( transObj, mlog );
22
23
return
p_TTColl;
24
25
}
//end of create persistent method
26
27
28
//createTransient
29
JetElementCollection
*
JetElementCollectionCnv::createTransient
(
const
Token
* token)
30
{
31
MsgStream mlog(msgSvc(),
"JetElementCollectionConverter"
);
32
33
//mlog << MSG::DEBUG << "JetElementCollectionCnv::createTransient called" << endmsg;
34
35
static
const
Guid
tlp1_guid(
"132ABB53-1F89-4E0E-83A3-382338B278F3"
);
36
static
const
Guid
p0_guid(
"48B92167-4892-4694-9E9E-E201F1E1FFFE"
);
37
38
JetElementCollection
*p_collection = 0;
39
if
(
compareClassGuid
(token, tlp1_guid ) )
40
{
41
// using unique_ptr ensures deletion of the persistent object
42
std::unique_ptr< JetElementCollection_PERS > pers_ref(
poolReadObject< JetElementCollection_PERS >
(token) );
43
p_collection =
m_TPConverter_tlp1
.createTransient( pers_ref.get(), mlog );
44
45
}
else
if
(
compareClassGuid
(token, p0_guid ) ){
46
47
p_collection =
poolReadObject< JetElementCollection >
(token);
48
49
}
else
throw
std::runtime_error(
"Unsupported persistent version of JetElementCollection"
);
50
51
return
p_collection;
52
53
}
//end of create transient method
54
JetElementCollectionCnv.h
Generated header file which defines a typedef for templated converter class.
JetElementCollection_PERS
JetElementCollection_tlp1 JetElementCollection_PERS
Definition
JetElementCollectionCnv.h:21
JetElementCollection
DataVector< LVL1::JetElement > JetElementCollection
Definition
JetElementCollection.h:10
Guid
This class provides a encapsulation of a GUID/UUID/CLSID/IID data structure (128 bit number).
Definition
Guid.h:25
JetElementCollectionCnv::createTransient
virtual JetElementCollection * createTransient(const Token *token)
Definition
JetElementCollectionCnv.cxx:29
JetElementCollectionCnv::createPersistent
virtual JetElementCollection_PERS * createPersistent(JetElementCollection *transCont)
Definition
JetElementCollectionCnv.cxx:14
JetElementCollectionCnv::m_TPConverter_tlp1
JetElementCollectionCnv_tlp1 m_TPConverter_tlp1
Definition
JetElementCollectionCnv.h:45
T_AthenaPoolCustomCnv< JetElementCollection, JetElementCollection_PERS >::compareClassGuid
virtual bool compareClassGuid(const Token *token, const Guid &clid) const
T_AthenaPoolCustomCnv< JetElementCollection, JetElementCollection_PERS >::poolReadObject
P * poolReadObject(const Token *token)
Token
This class provides a token that identifies in a unique way objects on the persistent storage.
Definition
Token.h:22
Generated on
for ATLAS Offline Software by
1.17.0