ATLAS Offline Software
Loading...
Searching...
No Matches
Control
AthenaKernel
AthenaKernel
ILockableTool.h
Go to the documentation of this file.
1
// This file's extension implies that it's C, but it's really -*- C++ -*-.
2
/*
3
* Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration.
4
*/
11
12
13
#ifndef ATHENAKERNEL_ILOCKABLETOOL_H
14
#define ATHENAKERNEL_ILOCKABLETOOL_H
15
16
24
class
ILockableTool
25
{
26
public
:
28
virtual
void
lock_shared
()
const
= 0;
29
31
virtual
void
unlock_shared
()
const
= 0;
32
};
33
34
35
namespace
Athena
{
36
37
42
class
ToolLock
43
{
44
public
:
46
ToolLock
(
ILockableTool
& tool)
47
:
m_tool
(tool)
48
{
49
m_tool
.lock_shared();
50
}
51
53
~ToolLock
()
54
{
55
m_tool
.unlock_shared();
56
}
57
58
59
private
:
60
ILockableTool
&
m_tool
;
61
};
62
63
64
}
// namespace Athena
65
66
67
68
#endif
// not ATHENAKERNEL_ILOCKABLETOOL_H
Athena::ToolLock::m_tool
ILockableTool & m_tool
Definition
ILockableTool.h:60
Athena::ToolLock::ToolLock
ToolLock(ILockableTool &tool)
Acquire the lock of tool.
Definition
ILockableTool.h:46
Athena::ToolLock::~ToolLock
~ToolLock()
Release the lock.
Definition
ILockableTool.h:53
ILockableTool
Provide an interface for locking and unlocking a tool externally.
Definition
ILockableTool.h:25
ILockableTool::lock_shared
virtual void lock_shared() const =0
Lock the tool.
ILockableTool::unlock_shared
virtual void unlock_shared() const =0
Unlock the tool.
Athena
Some weak symbol referencing magic... These are declared in AthenaKernel/getMessageSvc....
Definition
AthLegacySequence.h:21
Generated on
for ATLAS Offline Software by
1.14.0