ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Control
StoreGate
StoreGate
CondHandleKey.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_CONDHANDLEKEY_H
6
#define STOREGATE_CONDHANDLEKEY_H 1
7
8
#include "
AthenaKernel/CondCont.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
CondHandleKey
:
public
VarHandleKey
{
20
21
public
:
22
CondHandleKey
(
const
std::string&
key
,
23
const
std::string&
dbKey
,
24
Gaudi::DataHandle::Mode
a
);
25
26
// CondHandleKey& operator= (const std::string& sgkey);
27
28
StatusCode
initialize
(
bool
used
=
true
);
29
StatusCode
initialize
(
AllowEmptyEnum
);
30
31
const
std::string&
dbKey
()
const
{
return
m_dbKey
; }
32
void
setDbKey
(
const
std::string&
dbKey
) {
m_dbKey
=
dbKey
; }
33
34
42
virtual
StatusCode
start
()
override
;
43
44
45
protected
:
46
bool
isInit
()
const
{
return
m_isInit
; }
47
48
// Deliberately returning a non-const pointer here from a const
49
// member function. We don't own the CondCont, we just reference it.
50
// The Handle<> classes need to get a non-const CondCont from a
51
// const HandleKey<>.
52
CondCont<T>
* getCC
ATLAS_NOT_CONST_THREAD_SAFE
()
const
{
return
m_cc
; }
53
54
const
StoreGateSvc
*
getCS
()
const
;
55
56
private
:
57
58
ServiceHandle<StoreGateSvc>
m_cs
;
59
CondCont<T>
*
m_cc
{0};
60
61
std::string
m_dbKey
{
""
};
62
63
bool
m_isInit
{
false
};
64
65
};
66
67
68
}
69
70
#include "
StoreGate/CondHandleKey.icc
"
71
72
#endif
CondCont.h
Hold mappings of ranges to condition objects.
CondHandleKey.icc
a
static Double_t a
Definition
LArPhysWaveHECTool.cxx:38
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.
CondCont
Hold mapping of ranges to condition objects.
Definition
CondCont.h:889
SG::CondHandleKey::initialize
StatusCode initialize(AllowEmptyEnum)
SG::CondHandleKey::setDbKey
void setDbKey(const std::string &dbKey)
Definition
CondHandleKey.h:32
SG::CondHandleKey::CondHandleKey
CondHandleKey(const std::string &key, const std::string &dbKey, Gaudi::DataHandle::Mode a)
SG::CondHandleKey::m_cs
ServiceHandle< StoreGateSvc > m_cs
Definition
CondHandleKey.h:58
SG::CondHandleKey::getCS
const StoreGateSvc * getCS() const
SG::CondHandleKey::dbKey
const std::string & dbKey() const
Definition
CondHandleKey.h:31
SG::CondHandleKey::isInit
bool isInit() const
Definition
CondHandleKey.h:46
SG::CondHandleKey::m_isInit
bool m_isInit
Definition
CondHandleKey.h:63
SG::CondHandleKey::m_dbKey
std::string m_dbKey
Definition
CondHandleKey.h:61
SG::CondHandleKey::start
virtual StatusCode start() override
Called by the owning algorithm during the START transition.
SG::CondHandleKey::initialize
StatusCode initialize(bool used=true)
SG::CondHandleKey::m_cc
CondCont< T > * m_cc
Definition
CondHandleKey.h:59
SG::CondHandleKey::ATLAS_NOT_CONST_THREAD_SAFE
CondCont< T > *getCC ATLAS_NOT_CONST_THREAD_SAFE() const
Definition
CondHandleKey.h:52
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
used
holding In fact this class is here in order to allow STL container for all features This class is sho...
SG
Forward declaration.
Definition
CaloCellPacker_400_500.h:32
SG::AllowEmptyEnum
AllowEmptyEnum
Definition
StoreGate/StoreGate/VarHandleKey.h:26
Generated on
for ATLAS Offline Software by
1.17.0