ATLAS Offline Software
Event
xAOD
xAODCaloEvent
xAODCaloEvent
versions
CaloTowerContainer_v1.h
Go to the documentation of this file.
1
// -*- c++ -*-
2
3
/*
4
Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
5
*/
6
7
#ifndef XAODCALOEVENT_VERSIONS_CALOTOWERCONTAINER_V1_H
8
#define XAODCALOEVENT_VERSIONS_CALOTOWERCONTAINER_V1_H
9
10
#include "
AthContainers/DataVector.h
"
11
#include "
xAODBase/IParticleContainer.h
"
12
#include "
xAODCaloEvent/versions/CaloTower_v1.h
"
13
14
DATAVECTOR_BASE
(
xAOD::CaloTower_v1
,
xAOD::IParticle
);
15
16
namespace
xAOD
{
17
18
typedef
DataVector<CaloTower_v1>
CaloTowerContainerBase_v1
;
19
20
class
CaloTowerContainer_v1
:
public
CaloTowerContainerBase_v1
21
{
22
public
:
23
33
CaloTowerContainer_v1
(
SG::OwnershipPolicy
ownPolicy
=
SG::OWN_ELEMENTS
,
SG::IndexTrackingPolicy
trackIndices =
SG::DEFAULT_TRACK_INDICES
);
34
52
CaloTowerContainer_v1
(
int
nEtaBins
,
double
etaMin
,
double
etaMax
,
int
nPhiBins
,
SG::OwnershipPolicy
ownPolicy
=
SG::OWN_ELEMENTS
,
SG::IndexTrackingPolicy
trackIndices =
SG::DEFAULT_TRACK_INDICES
);
53
54
56
~CaloTowerContainer_v1
();
57
70
71
bool
configureGrid
(
int
nEtaBins
,
double
etaMin
,
double
etaMax
,
int
nPhiBins
);
73
77
int
nEtaBins
()
const
;
78
double
etaMin
()
const
;
79
double
etaMax
()
const
;
80
double
deltaEta
()
const
;
81
int
nPhiBins
()
const
;
82
double
phiMin
()
const
;
83
double
phiMax
()
const
;
84
double
deltaPhi
()
const
;
85
int
nTowers
()
const
;
86
88
91
int
index
(
double
eta
,
double
phi
)
const
;
92
double
eta
(
size_t
index
)
const
;
93
double
phi
(
size_t
index
)
const
;
94
95
const
CaloTower_v1
*
tower
(
double
eta
,
double
phi
)
const
;
97
98
private
:
99
100
bool
configureGrid
();
101
104
unsigned
short
m_nEtaBins
;
105
double
m_etaMin
;
106
double
m_etaMax
;
107
unsigned
short
m_nPhiBins
;
108
double
m_deltaEta
;
109
double
m_deltaPhi
;
110
bool
m_isConfigured
=
false
;
111
};
113
}
114
139
140
141
#include "
xAODCore/BaseInfo.h
"
142
//SG_BASE(xAOD::CaloTowerContainer_v1, DataVector<xAOD::CaloTower_v1>);
143
SG_BASE
(
xAOD::CaloTowerContainer_v1
,
xAOD::CaloTowerContainerBase_v1
);
144
145
inline
int
xAOD::CaloTowerContainer_v1::nEtaBins
()
const
{
return
m_nEtaBins
; }
146
inline
int
xAOD::CaloTowerContainer_v1::nPhiBins
()
const
{
return
m_nPhiBins; }
147
inline
int
xAOD::CaloTowerContainer_v1::nTowers
()
const
{
return
m_nEtaBins*m_nPhiBins;}
148
149
inline
double
xAOD::CaloTowerContainer_v1::etaMin
()
const
{
return
m_etaMin; }
150
inline
double
xAOD::CaloTowerContainer_v1::etaMax
()
const
{
return
m_etaMax; }
151
inline
double
xAOD::CaloTowerContainer_v1::deltaEta
()
const
{
return
m_deltaEta; }
152
153
inline
double
xAOD::CaloTowerContainer_v1::phiMin
()
const
{
return
-
M_PI
; }
154
inline
double
xAOD::CaloTowerContainer_v1::phiMax
()
const
{
return
M_PI
; }
155
inline
double
xAOD::CaloTowerContainer_v1::deltaPhi
()
const
{
return
m_deltaPhi; }
156
157
inline
const
xAOD::CaloTower_v1
*
xAOD::CaloTowerContainer_v1::tower
(
double
eta,
double
phi
)
const
{
158
int
idx
=
index
(eta,
phi
);
159
if
(
idx
>0 &&
idx
<(
int
)this->
size
()) {
160
return
(*
this
)[
idx
];
161
}
162
163
return
nullptr
;
164
}
165
166
#endif
xAOD::CaloTowerContainer_v1::m_deltaEta
double m_deltaEta
Definition:
CaloTowerContainer_v1.h:108
xAOD::CaloTowerContainer_v1
Basic container storing all information need for xAOD::CaloTower_v1 objects.
Definition:
CaloTowerContainer_v1.h:21
index
Definition:
index.py:1
M_PI
#define M_PI
Definition:
ActiveFraction.h:11
BaseInfo.h
CaloTower_v1.h
SG::DEFAULT_TRACK_INDICES
@ DEFAULT_TRACK_INDICES
Default value.
Definition:
IndexTrackingPolicy.h:40
xAOD
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
Definition:
ICaloAffectedTool.h:24
xAOD::CaloTowerContainer_v1::m_etaMax
double m_etaMax
Definition:
CaloTowerContainer_v1.h:106
xAOD::IParticle
Class providing the definition of the 4-vector interface.
Definition:
Event/xAOD/xAODBase/xAODBase/IParticle.h:41
SG::OwnershipPolicy
OwnershipPolicy
describes the possible element ownership policies (see e.g. DataVector)
Definition:
OwnershipPolicy.h:16
xAOD::CaloTowerContainer_v1::configureGrid
bool configureGrid()
Definition:
CaloTowerContainer_v1.cxx:51
xAOD::phi
setEt phi
Definition:
TrigEMCluster_v1.cxx:29
python.setupRTTAlg.size
int size
Definition:
setupRTTAlg.py:39
xAOD::CaloTowerContainer_v1::m_deltaPhi
double m_deltaPhi
Definition:
CaloTowerContainer_v1.h:109
xAOD::CaloTowerContainer_v1::nEtaBins
int nEtaBins() const
Definition:
CaloTowerContainer_v1.h:145
xAOD::CaloTowerContainer_v1::m_isConfigured
bool m_isConfigured
Definition:
CaloTowerContainer_v1.h:110
SG::OWN_ELEMENTS
@ OWN_ELEMENTS
this data object owns its elements
Definition:
OwnershipPolicy.h:17
IParticleContainer.h
xAOD::CaloTowerContainer_v1::m_nPhiBins
unsigned short m_nPhiBins
Definition:
CaloTowerContainer_v1.h:107
xAOD::CaloTowerContainer_v1::m_nEtaBins
unsigned short m_nEtaBins
Definition:
CaloTowerContainer_v1.h:104
xAOD::CaloTowerContainer_v1::m_etaMin
double m_etaMin
Definition:
CaloTowerContainer_v1.h:105
DataVector
Derived DataVector<T>.
Definition:
DataVector.h:581
xAOD::CaloTowerContainer_v1::etaMin
double etaMin() const
Definition:
CaloTowerContainer_v1.h:149
xAOD::CaloTowerContainerBase_v1
DataVector< CaloTower_v1 > CaloTowerContainerBase_v1
Definition:
CaloTowerContainer_v1.h:18
xAOD::CaloTowerContainer_v1::nTowers
int nTowers() const
Definition:
CaloTowerContainer_v1.h:147
DATAVECTOR_BASE
DATAVECTOR_BASE(xAOD::CaloTower_v1, xAOD::IParticle)
xAOD::CaloTowerContainer_v1::CaloTowerContainer_v1
CaloTowerContainer_v1(SG::OwnershipPolicy ownPolicy=SG::OWN_ELEMENTS, SG::IndexTrackingPolicy trackIndices=SG::DEFAULT_TRACK_INDICES)
Default constructor Constructs a tower container without structure (binning) or content.
Definition:
CaloTowerContainer_v1.cxx:23
xAOD::CaloTowerContainer_v1::phi
double phi(size_t index) const
Definition:
CaloTowerContainer_v1.cxx:86
xAOD::CaloTowerContainer_v1::~CaloTowerContainer_v1
~CaloTowerContainer_v1()
Destructor.
Definition:
CaloTowerContainer_v1.cxx:36
xAOD::CaloTowerContainer_v1::phiMax
double phiMax() const
Definition:
CaloTowerContainer_v1.h:154
xAOD::CaloTowerContainer_v1::deltaEta
double deltaEta() const
Definition:
CaloTowerContainer_v1.h:151
DataVector.h
An STL vector of pointers that by default owns its pointed-to elements.
DeMoScan.index
string index
Definition:
DeMoScan.py:364
xAOD::CaloTowerContainer_v1::etaMax
double etaMax() const
Definition:
CaloTowerContainer_v1.h:150
LArNewCalib_DelayDump_OFC_Cali.idx
idx
Definition:
LArNewCalib_DelayDump_OFC_Cali.py:69
xAOD::CaloTowerContainer_v1::phiMin
double phiMin() const
Definition:
CaloTowerContainer_v1.h:153
DataVector::ownPolicy
SG::OwnershipPolicy ownPolicy() const
Return the ownership policy setting for this container.
xAOD::CaloTower_v1
!
Definition:
CaloTower_v1.h:18
SG_BASE
SG_BASE(xAOD::CaloTowerContainer_v1, xAOD::CaloTowerContainerBase_v1)
xAOD::CaloTowerContainer_v1::index
int index(double eta, double phi) const
Definition:
CaloTowerContainer_v1.cxx:65
xAOD::CaloTowerContainer_v1::tower
const CaloTower_v1 * tower(double eta, double phi) const
Definition:
CaloTowerContainer_v1.h:157
xAOD::CaloTowerContainer_v1::nPhiBins
int nPhiBins() const
Definition:
CaloTowerContainer_v1.h:146
SG::IndexTrackingPolicy
IndexTrackingPolicy
Definition:
IndexTrackingPolicy.h:37
xAOD::CaloTowerContainer_v1::eta
double eta(size_t index) const
Definition:
CaloTowerContainer_v1.cxx:77
xAOD::CaloTowerContainer_v1::deltaPhi
double deltaPhi() const
Definition:
CaloTowerContainer_v1.h:155
Generated on Thu Nov 7 2024 21:11:46 for ATLAS Offline Software by
1.8.18