ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Control
AthToolSupport
AsgTools
AsgTools
AsgTool.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 ASGTOOLS_ASGTOOL_H
6
#define ASGTOOLS_ASGTOOL_H
7
8
// Athena include(s).
9
#include "
SGCore/sgkey_t.h
"
10
11
// Local include(s):
12
#include "
AsgTools/IAsgTool.h
"
13
#include "
AsgMessaging/MsgLevel.h
"
14
#include "
AsgMessaging/MessageCheck.h
"
15
16
// Environment specific include(s):
17
#ifdef XAOD_STANDALONE
18
# include "
AsgMessaging/AsgMessaging.h
"
19
# include "
AsgTools/AsgComponent.h
"
20
# include "
AsgTools/SgEvent.h
"
21
// Forward declaration(s):
22
#else
// XAOD_STANDALONE
23
# include "
AthenaBaseComps/AthAlgTool.h
"
24
#endif
// XAOD_STANDALONE
25
26
// System include(s).
27
#include <string>
28
29
namespace
asg
{
30
31
// Declare the type name of AsgTool's base class
32
#ifndef XAOD_STANDALONE
33
typedef
::AthAlgTool
AsgToolBase
;
34
#else
// not XAOD_STANDALONE
35
typedef
AsgComponent
AsgToolBase
;
36
#endif
// not XAOD_STANDALONE
37
46
class
AsgTool
:
public
virtual
IAsgTool
,
47
public
AsgToolBase
{
48
49
public
:
51
AsgTool
(
const
std::string& name );
53
~AsgTool
();
54
55
AsgTool
(
const
AsgTool
&) =
delete
;
56
AsgTool
&
operator=
(
const
AsgTool
&) =
delete
;
57
58
59
#ifdef XAOD_STANDALONE
60
62
SgEvent
*
evtStore
()
const
;
63
64
// this is just so that my template functions can find this
65
// method in the base class.
66
public
:
67
using
AsgToolBase::msg
;
68
69
#endif
// XAOD_STANDALONE
70
71
#ifndef XAOD_STANDALONE
72
public
:
74
using
::AthAlgTool::getProperty;
75
76
#endif
// not XAOD_STANDALONE
77
80
82
template
<
class
T >
83
const
T*
getProperty
(
const
std::string& name )
const
;
84
86
const
std::string&
msg_level_name
()
const
__attribute__
((deprecated));
87
105
const
std
::
string
&
getName
(
const
void
* ptr )
const
;
106
124
SG
::sgkey_t
getKey
(
const
void
* ptr )
const
;
125
127
133
virtual StatusCode
initialize
() {
return
StatusCode::SUCCESS; }
134
136
virtual
void
print
()
const
;
137
138
private
:
139
#ifdef XAOD_STANDALONE
140
mutable
SgEvent
m_event;
141
#endif
// XAOD_STANDALONE
142
143
};
// class AsgTool
144
145
}
// namespace asg
146
147
// Include the implementation of the template functions:
148
#include "
AsgTools/AsgTool.icc
"
149
150
// Include static methods for working with AsgTools
151
#include "
AsgTools/SetProperty.h
"
152
153
#endif
// ASGTOOLS_ASGTOOL_H
AsgComponent.h
AsgMessaging.h
AsgTool.icc
AthAlgTool.h
MessageCheck.h
macros for messaging and checking status codes
IAsgTool.h
MsgLevel.h
Definition of message levels and a helper function.
SetProperty.h
SgEvent.h
__attribute__
__attribute__((always_inline)) inline uint16_t TileCalibDrawerBase
Definition
TileCalibDrawerBase.h:192
AthAlgTool
Definition
AthAlgTool.h:26
AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore
ServiceHandle< StoreGateSvc > & evtStore()
Definition
AthCommonDataStore.h:85
AthCommonMsg< AlgTool >::msg
MsgStream & msg() const
Definition
AthCommonMsg.h:24
asg::AsgTool::getProperty
const T * getProperty(const std::string &name) const
Get one of the tool's properties.
asg::AsgTool::msg_level_name
const std::string & msg_level_name() const __attribute__((deprecated))
A deprecated function for getting the message level's name.
Definition
AsgTool.cxx:101
asg::AsgTool::AsgTool
AsgTool(const std::string &name)
Constructor specifying the tool instance's name.
Definition
AsgTool.cxx:58
asg::AsgTool::initialize
virtual StatusCode initialize()
Dummy implementation of the initialisation function.
Definition
AsgTool.h:133
asg::AsgTool::getName
const std::string & getName(const void *ptr) const
Get the name of an object that is / should be in the event store.
Definition
AsgTool.cxx:106
asg::AsgTool::operator=
AsgTool & operator=(const AsgTool &)=delete
asg::AsgTool::~AsgTool
~AsgTool()
Destructor.
Definition
AsgTool.cxx:73
asg::AsgTool::print
virtual void print() const
Print the state of the tool.
Definition
AsgTool.cxx:131
asg::AsgTool::getKey
SG::sgkey_t getKey(const void *ptr) const
Get the (hashed) key of an object that is in the event store.
Definition
AsgTool.cxx:119
asg::AsgTool::AsgTool
AsgTool(const AsgTool &)=delete
asg::IAsgTool
Base class for the dual-use tool interface classes.
Definition
IAsgTool.h:41
asg::SgEvent
Wrapper for Event to make it look like StoreGate.
Definition
SgEvent.h:44
const
SG
Forward declaration.
Definition
CaloCellPacker_400_500.h:32
asg
Definition
DataHandleTestTool.h:28
asg::AsgToolBase
::AthAlgTool AsgToolBase
Definition
AsgTool.h:33
std
STL namespace.
sgkey_t.h
Generated on
for ATLAS Offline Software by
1.17.0