ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Calorimeter
CaloUtils
src
CaloCellCorrection.cxx
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
/********************************************************************
6
7
NAME: CaloCellCorrection.h used to be LArCellCorrection.h
8
PACKAGE: offline/Calorimeter/CaloUtils
9
10
AUTHORS: H. Ma, S. Rajagopalan
11
CREATED: Dec. 15, 1999
12
13
PURPOSE: Performs cell corrections for CaloCell objects
14
This is the base class for individual cell correction classes.
15
16
17
Updated: May 10, 2000 (SR, HM)
18
Migrated to Athena Framework from PASO
19
20
Updated: Jan. 2, 2001 (SR)
21
Adhere to QC standards (based on comments from S. Albrand)
22
23
Updated: Jan 2003
24
Made to an AlgTool,
25
Moved to LArCalorimeter/LArRecUtils
26
27
Update : June 2004 David Rousseau
28
Change name
29
Work off CaloCell, not LArCell anymore, without friend mechanism
30
31
********************************************************************/
32
33
// Calo Header files:
34
35
#include "
CaloUtils/CaloCellCorrection.h
"
36
#include "
CaloEvent/CaloCellContainer.h
"
37
#include "
CaloEvent/CaloCell.h
"
38
39
#include "
AthenaBaseComps/AthAlgTool.h
"
40
41
// DESTRUCTOR:
42
43
CaloCellCorrection::~CaloCellCorrection
()
44
=
default
;
45
47
// EXECUTE method: Correct cells in input cell container
49
50
StatusCode
CaloCellCorrection::execute
(
CaloCellContainer
* cellCollection,
51
const
EventContext& ctx)
const
52
{
53
54
ATH_MSG_DEBUG
(
"Executing CaloCellCorrection"
);
55
56
if
(!cellCollection) {
57
ATH_MSG_ERROR
(
"Cell Correction tool receives invalid cell Collection"
);
58
return
StatusCode::FAILURE;
59
}
60
61
// Loop over all the CaloCell Objects and call Make Correction.
62
// Note that this is the base class of all the concrete correction
63
// classes which implement a Make Correction method.
64
65
for
(
CaloCell
* cell : *cellCollection) {
66
MakeCorrection
( cell, ctx );
67
}
68
69
// Done, Return success
70
71
return
StatusCode::SUCCESS;
72
73
}
74
76
// Other methods:
77
// The following methods "correct" the CaloCell data members.
79
80
81
void
CaloCellCorrection::setenergy
(
CaloCell
* theCell,
float
energy)
82
{
83
theCell->
setEnergy
( energy );
84
}
85
86
void
CaloCellCorrection::addenergy
(
CaloCell
* theCell,
float
energy)
87
{
88
theCell->
addEnergy
( energy );
89
}
90
91
void
CaloCellCorrection::scaleenergy
(
CaloCell
* theCell,
float
scale)
92
{
93
theCell->
scaleEnergy
( scale );
94
}
AthAlgTool.h
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition
AthMsgStreamMacros.h:33
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition
AthMsgStreamMacros.h:29
CaloCellContainer.h
CaloCellCorrection.h
CaloCell.h
CaloCellContainer
Container class for CaloCell.
Definition
CaloCellContainer.h:55
CaloCellCorrection::addenergy
static void addenergy(CaloCell *lar_cell, float energy)
Definition
CaloCellCorrection.cxx:86
CaloCellCorrection::execute
virtual StatusCode execute(CaloCellContainer *cellCollection, const EventContext &ctx) const
Definition
CaloCellCorrection.cxx:50
CaloCellCorrection::setenergy
static void setenergy(CaloCell *lar_cell, float energy)
Definition
CaloCellCorrection.cxx:81
CaloCellCorrection::~CaloCellCorrection
virtual ~CaloCellCorrection()
CaloCellCorrection::scaleenergy
static void scaleenergy(CaloCell *lar_cell, float scale)
Definition
CaloCellCorrection.cxx:91
CaloCellCorrection::MakeCorrection
virtual void MakeCorrection(CaloCell *cellCollection, const EventContext &ctx) const =0
CaloCell
Data object for each calorimeter readout cell.
Definition
CaloCell.h:57
CaloCell::addEnergy
void addEnergy(float energy)
add energy
Definition
CaloCell.h:449
CaloCell::setEnergy
virtual void setEnergy(float energy)
set energy
Definition
CaloCell.h:472
CaloCell::scaleEnergy
virtual void scaleEnergy(float scale)
scale energy
Definition
CaloCell.h:478
Generated on
for ATLAS Offline Software by
1.17.0