ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Control
StoreGate
StoreGate
MetaHandleKey.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef STOREGATE_METAHANDLEKEY_H
6
#define STOREGATE_METAHANDLEKEY_H
7
8
#include "
AthenaKernel/MetaCont.h
"
9
#include "
StoreGate/VarHandleKey.h
"
10
#include "
StoreGate/StoreGateSvc.h
"
11
#include "
CxxUtils/checker_macros.h
"
12
#include "GaudiKernel/ServiceHandle.h"
13
#include "GaudiKernel/MsgStream.h"
14
#include "GaudiKernel/IClassIDSvc.h"
15
16
namespace
SG
{
17
18
template
<
class
T>
19
class
MetaHandleKey
:
public
VarHandleKey
{
20
21
public
:
22
MetaHandleKey
(
const
std::string&
key
,
23
const
std::string&
dbKey
,
24
Gaudi::DataHandle::Mode
a
);
25
26
StatusCode
initialize
();
27
28
const
MetaContBase::SourceID
&
dbKey
()
const
{
return
m_dbKey
; }
29
void
setDbKey
(
const
MetaContBase::SourceID
&
dbKey
) {
m_dbKey
=
dbKey
; }
30
31
protected
:
32
bool
isInit
()
const
{
return
m_isInit
; }
33
34
// Deliberately returning a non-const pointer here from a const
35
// member function. We don't own the MetaCont, we just reference it.
36
// The Handle<> classes need to get a non-const MetaCont from a
37
// const HandleKey<>.
38
MetaCont<T>
* getContainer
ATLAS_NOT_CONST_THREAD_SAFE
()
const
{
return
m_cont
; }
39
40
const
StoreGateSvc
*
getStore
()
const
;
41
42
private
:
43
44
ServiceHandle<StoreGateSvc>
m_store
;
45
MetaCont<T>
*
m_cont
{
nullptr
};
46
47
MetaContBase::SourceID
m_dbKey
{
""
};
48
49
bool
m_isInit
{
false
};
50
51
};
52
53
54
}
55
56
#include "
StoreGate/MetaHandleKey.icc
"
57
58
#endif
a
static Double_t a
Definition
LArPhysWaveHECTool.cxx:38
MetaCont.h
MetaHandleKey.icc
StoreGateSvc.h
VarHandleKey.h
A property holding a SG store/key/clid from which a VarHandle is made.
checker_macros.h
Define macros for attributes used to control the static checker.
MetaContBase::SourceID
SG::SourceID SourceID
Definition
MetaCont.h:26
MetaCont
Definition
MetaCont.h:48
SG::MetaHandleKey::isInit
bool isInit() const
Definition
MetaHandleKey.h:32
SG::MetaHandleKey::setDbKey
void setDbKey(const MetaContBase::SourceID &dbKey)
Definition
MetaHandleKey.h:29
SG::MetaHandleKey::ATLAS_NOT_CONST_THREAD_SAFE
MetaCont< T > *getContainer ATLAS_NOT_CONST_THREAD_SAFE() const
Definition
MetaHandleKey.h:38
SG::MetaHandleKey::m_store
ServiceHandle< StoreGateSvc > m_store
Definition
MetaHandleKey.h:44
SG::MetaHandleKey::initialize
StatusCode initialize()
SG::MetaHandleKey::dbKey
const MetaContBase::SourceID & dbKey() const
Definition
MetaHandleKey.h:28
SG::MetaHandleKey::m_dbKey
MetaContBase::SourceID m_dbKey
Definition
MetaHandleKey.h:47
SG::MetaHandleKey::m_isInit
bool m_isInit
Definition
MetaHandleKey.h:49
SG::MetaHandleKey::MetaHandleKey
MetaHandleKey(const std::string &key, const std::string &dbKey, Gaudi::DataHandle::Mode a)
SG::MetaHandleKey::getStore
const StoreGateSvc * getStore() const
SG::MetaHandleKey::m_cont
MetaCont< T > * m_cont
Definition
MetaHandleKey.h:45
SG::VarHandleKey::key
const std::string & key() const
Return the StoreGate ID for the referenced object.
Definition
AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:141
SG::VarHandleKey::VarHandleKey
VarHandleKey(CLID clid, const std::string &sgkey, Gaudi::DataHandle::Mode a, const std::string &storeName=StoreID::storeName(StoreID::EVENT_STORE), bool isCond=false)
Constructor.
Definition
AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:38
ServiceHandle
Definition
ClusterMakerTool.h:36
StoreGateSvc
The Athena Transient Store API.
Definition
StoreGateSvc.h:120
SG
Forward declaration.
Definition
CaloCellPacker_400_500.h:32
Generated on
for ATLAS Offline Software by
1.17.0