ATLAS Offline Software
Loading...
Searching...
No Matches
Control
DataModelAthenaPool
DataModelAthenaPool
ElementLink_p1.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef DATAMODELATHENAPOOL_ELEMENTLINK_P1_H
6
#define DATAMODELATHENAPOOL_ELEMENTLINK_P1_H
7
12
13
#include <string>
14
#include <inttypes.h>
15
16
#include "
SGCore/sgkey_t.h
"
17
21
22
template
<
class
INDEXTYPE>
23
class
ElementLink_p1
{
24
public
:
25
26
ElementLink_p1
() :
m_elementIndex
(),
m_SGKeyHash
(0) {}
27
28
std::string
m_contName
;
29
INDEXTYPE
m_elementIndex
;
30
SG::sgkey_t
m_SGKeyHash
;
// replaces m_contName
31
};
32
33
34
// If you define more ElementLink_pN types, remember to add template instantiations to the Dict file
35
36
typedef
ElementLink_p1<uint32_t>
ElementLinkInt_p1
;
37
typedef
ElementLink_p1<std::string>
ElementLinkStr_p1
;
38
39
40
// Helper template for conversion from the index type in transient ElementLink
41
// to the persistent index type
42
43
template
<
typename
ContIndxType>
44
struct
GenerateELinkIndexType_p1
{
45
// typedef MISSING_DEFINITION_OF_GenerateELinkIndexType_FOR_<ContIndxType> type;
46
};
47
48
template
<>
49
struct
GenerateELinkIndexType_p1
<uint32_t> {
50
typedef
uint32_t
type
;
51
};
52
53
template
<>
54
struct
GenerateELinkIndexType_p1
<uint64_t> {
55
typedef
uint32_t
type
;
56
};
57
58
template
<>
59
struct
GenerateELinkIndexType_p1
<int> {
60
typedef
uint32_t
type
;
61
};
62
63
#ifdef __APPLE__
64
template
<>
65
struct
GenerateELinkIndexType_p1
<size_t> {
66
typedef
uint32_t
type
;
67
};
68
#endif
69
70
template
<>
71
struct
GenerateELinkIndexType_p1
<
std
::
string
> {
72
typedef
std::string
type
;
73
};
74
75
76
// Helper template to generate type of the persistent ElementLink_pN
77
// from the type of the transient ElementLink
78
// Used in the ElementlinkCnv_pN
79
80
template
<
class
LINK>
81
struct
GeneratePersELinkType_p1
{
82
typedef
ElementLink_p1<typename GenerateELinkIndexType_p1<typename LINK::index_type>::type
>
type
;
83
};
84
85
#endif
// DATAMODELATHENAPOOL_ELEMENTLINK_P1_H
ElementLinkStr_p1
ElementLink_p1< std::string > ElementLinkStr_p1
Definition
ElementLink_p1.h:37
ElementLinkInt_p1
ElementLink_p1< uint32_t > ElementLinkInt_p1
Definition
ElementLink_p1.h:36
ElementLink_p1
Definition
ElementLink_p1.h:23
ElementLink_p1< uint32_t >::m_SGKeyHash
SG::sgkey_t m_SGKeyHash
Definition
ElementLink_p1.h:30
ElementLink_p1< uint32_t >::m_contName
std::string m_contName
Definition
ElementLink_p1.h:28
ElementLink_p1< uint32_t >::m_elementIndex
uint32_t m_elementIndex
Definition
ElementLink_p1.h:29
ElementLink_p1::ElementLink_p1
ElementLink_p1()
Definition
ElementLink_p1.h:26
string
STL class.
SG::sgkey_t
uint32_t sgkey_t
Type used for hashed StoreGate key+CLID pairs.
Definition
sgkey_t.h:32
std
STL namespace.
sgkey_t.h
GenerateELinkIndexType_p1< int >::type
uint32_t type
Definition
ElementLink_p1.h:60
GenerateELinkIndexType_p1< std::string >::type
std::string type
Definition
ElementLink_p1.h:72
GenerateELinkIndexType_p1< uint32_t >::type
uint32_t type
Definition
ElementLink_p1.h:50
GenerateELinkIndexType_p1< uint64_t >::type
uint32_t type
Definition
ElementLink_p1.h:55
GenerateELinkIndexType_p1
Definition
ElementLink_p1.h:44
type
GeneratePersELinkType_p1::type
ElementLink_p1< typename GenerateELinkIndexType_p1< typename LINK::index_type >::type > type
Definition
ElementLink_p1.h:82
Generated on
for ATLAS Offline Software by
1.14.0