ATLAS Offline Software
Reconstruction
Jet
JetRec
src
JetDecorationAlg.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#include "
JetRec/JetDecorationAlg.h
"
6
#include "
AsgDataHandles/ReadHandle.h
"
7
8
9
StatusCode
JetDecorationAlg::initialize
() {
10
11
ATH_CHECK
(
m_jetKey
.initialize());
12
if
(
m_decorators
.empty()){
13
ATH_MSG_FATAL
(
"No decorators were given"
);
14
return
StatusCode::FAILURE;
15
}
16
ATH_CHECK
(
m_decorators
.retrieve());
17
ATH_MSG_INFO
(
"Initialize .... List of decorators:"
);
18
for
(
const
ToolHandle<IJetDecorator>&
t
:
m_decorators
){
19
ATH_MSG_INFO
(
" --> : "
<<
t
->name());
20
}
21
22
return
StatusCode::SUCCESS;
23
}
24
25
26
StatusCode
JetDecorationAlg::execute
(
const
EventContext& ctx)
const
{
27
28
SG::ReadHandle<xAOD::JetContainer>
jetHandle(
m_jetKey
, ctx);
29
30
ATH_MSG_DEBUG
(
"Applying jet decorators to "
<<
m_jetKey
.key());
31
for
(
const
ToolHandle<IJetDecorator>&
t
:
m_decorators
){
32
ATH_MSG_DEBUG
(
"Running "
<<
t
.name());
33
ATH_CHECK
(
t
->decorate(*jetHandle));
34
}
35
36
return
StatusCode::SUCCESS;
37
38
}
ATH_MSG_FATAL
#define ATH_MSG_FATAL(x)
Definition:
AthMsgStreamMacros.h:34
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition:
AthMsgStreamMacros.h:31
SG::ReadHandle
Definition:
StoreGate/StoreGate/ReadHandle.h:70
read_hist_ntuple.t
t
Definition:
read_hist_ntuple.py:5
JetDecorationAlg.h
JetDecorationAlg::execute
StatusCode execute(const EventContext &ctx) const override
Definition:
JetDecorationAlg.cxx:26
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition:
PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition:
AthMsgStreamMacros.h:29
ATH_CHECK
#define ATH_CHECK
Definition:
AthCheckMacros.h:40
JetDecorationAlg::initialize
StatusCode initialize() override
Athena algorithm's Hooks.
Definition:
JetDecorationAlg.cxx:9
ReadHandle.h
Handle class for reading from StoreGate.
JetDecorationAlg::m_jetKey
SG::ReadHandleKey< xAOD::JetContainer > m_jetKey
Definition:
JetDecorationAlg.h:36
JetDecorationAlg::m_decorators
ToolHandleArray< IJetDecorator > m_decorators
Definition:
JetDecorationAlg.h:35
Generated on Sun Dec 22 2024 21:12:27 for ATLAS Offline Software by
1.8.18