ATLAS Offline Software
Loading...
Searching...
No Matches
egammaRec.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef EGAMMARECEVENT_EGAMMA_H
6#define EGAMMARECEVENT_EGAMMA_H
12// INCLUDE HEADER FILES:
13
14#include "AthLinks/ElementLink.h"
15
16// CaloCluster include
19
20// TrackParticle Includes
23
24// Vertex Includes
25#include "xAODTracking/Vertex.h"
27
28#include <array>
29#include <vector>
31{
33 // Public typedefs:
35public:
37 egammaRec() = default;
38
40 egammaRec(const std::vector<ElementLink<xAOD::CaloClusterContainer>> &caloClusterLinks);
41
45 egammaRec(const egammaRec&) = default;
46 egammaRec(egammaRec&&) = default;
47 egammaRec& operator=(const egammaRec&) = default;
49 ~egammaRec() = default;
50
52 size_t getNumberOfClusters() const;
53
55 const xAOD::CaloCluster* caloCluster(size_t index = 0) const;
56
59
62
64 const std::vector<ElementLink<xAOD::CaloClusterContainer>> & caloClusterElementLinks() const;
65
68
70 const xAOD::TrackParticle* trackParticle(size_t index = 0) const;
71
74
77
79 const std::vector<ElementLink<xAOD::TrackParticleContainer>> & trackParticleElementLinks() const;
80
82 size_t getNumberOfVertices() const;
83
85 const xAOD::Vertex* vertex(size_t index = 0) const;
86
89
91 void setVertices(const std::vector<ElementLink<xAOD::VertexContainer>>& links);
92
94 const std::vector<ElementLink<xAOD::VertexContainer>> & vertexElementLinks() const;
95
98
101
104
105 const std::array<double,4>& deltaEta () const;
106
108 const std::array<double,4>& deltaPhi () const;
109
111 const std::array<double,4>& deltaPhiRescaled () const;
112
114 double deltaPhiLast () const ;
115
117 void setDeltaEta(const std::array<double, 4>& deltaEtas);
118
120 void setDeltaPhi(const std::array<double, 4>& deltaPhis);
121
124 void setDeltaPhiRescaled(std::array<double, 4>& deltaPhis);
125
127 void setDeltaPhiLast(double value);
129
132
133 float deltaEtaVtx() const;
134
136 float deltaPhiVtx() const;
137
139 void setDeltaEtaVtx(float value);
140
142 void setDeltaPhiVtx(float value);
144
145private:
146 std::vector<ElementLink<xAOD::CaloClusterContainer>> m_caloClusters;
147 std::vector<ElementLink<xAOD::TrackParticleContainer>> m_trackParticles;
148 std::vector<ElementLink<xAOD::VertexContainer>> m_vertices;
149
150 std::array<double, 4> m_deltaEta {-999, -999, -999, -999};
151 std::array<double, 4> m_deltaPhi {-999, -999, -999, -999};
152 std::array<double, 4> m_deltaPhiRescaled {-999, -999, -999, -999};
153
154 double m_deltaPhiLast = -999;
155 float m_deltaEtaVtx = -999;
156 float m_deltaPhiVtx = -999;
157};
158#include"egammaRec.icc"
159#endif
160
size_t getNumberOfClusters() const
Return the number of xAOD::CaloClusters that define the electron candidate.
double deltaPhiLast() const
deltaPhi from Last measurement
const std::vector< ElementLink< xAOD::CaloClusterContainer > > & caloClusterElementLinks() const
Get a reference to the calo cluster links.
Definition egammaRec.cxx:26
egammaRec(const egammaRec &)=default
Default copy/move ctor/assignment dtor.
void pushBackVertex(const ElementLink< xAOD::VertexContainer > &vertexElementLink)
Push back another vertex.
Definition egammaRec.cxx:76
size_t getNumberOfTrackParticles() const
Return the number xAOD::TrackParticles that match the electron candidate.
const std::vector< ElementLink< xAOD::TrackParticleContainer > > & trackParticleElementLinks() const
Get a reference to the track particle links.
Definition egammaRec.cxx:49
egammaRec & operator=(egammaRec &&)=default
std::vector< ElementLink< xAOD::TrackParticleContainer > > m_trackParticles
Definition egammaRec.h:147
void pushFrontVertex(const ElementLink< xAOD::VertexContainer > &vertexElementLink)
Push front another vertex.
Definition egammaRec.cxx:82
const std::array< double, 4 > & deltaPhiRescaled() const
deltaPhi for rescaled momentum extrapolation from the perigee.
std::array< double, 4 > m_deltaPhi
Definition egammaRec.h:151
egammaRec()=default
Default constructor implemented.
void setDeltaEta(const std::array< double, 4 > &deltaEtas)
set deltaEta at pre sampler(0) -> 3rd sampling(3)
float deltaPhiVtx() const
deltaPhiVtx
const xAOD::Vertex * vertex(size_t index=0) const
Pointer to the xAOD::Vertex/es that match the photon candidate.
Definition egammaRec.cxx:54
const std::vector< ElementLink< xAOD::VertexContainer > > & vertexElementLinks() const
Get a reference to the vertix links.
Definition egammaRec.cxx:71
egammaRec(const std::vector< ElementLink< xAOD::CaloClusterContainer > > &caloClusterLinks)
Constructor which adds cluster links.
std::array< double, 4 > m_deltaEta
Definition egammaRec.h:150
std::array< double, 4 > m_deltaPhiRescaled
Definition egammaRec.h:152
std::vector< ElementLink< xAOD::CaloClusterContainer > > m_caloClusters
Definition egammaRec.h:146
std::vector< ElementLink< xAOD::VertexContainer > > m_vertices
Definition egammaRec.h:148
float deltaEtaVtx() const
deltaEtaVtx
void setCaloClusters(const std::vector< ElementLink< xAOD::CaloClusterContainer > > &links)
set Pointer to the xAOD::CaloCluster
void setDeltaPhiLast(double value)
set deltaPhi at sampling 2 from Last track Measurement
double m_deltaPhiLast
Definition egammaRec.h:154
void setDeltaPhiVtx(float value)
set deltaPhiVtx
void setDeltaPhiRescaled(std::array< double, 4 > &deltaPhis)
set deltaPhi at sampling for rescaled momentum extrapolation from the perigee.
const std::array< double, 4 > & deltaEta() const
deltaEta at pre sampler(0) -> 3rd sampling(3)
~egammaRec()=default
void setTrackParticles(const std::vector< ElementLink< xAOD::TrackParticleContainer > > &links)
Set the ElementLinks to the xAOD::TrackParticle/s that match the electron candidate.
const std::array< double, 4 > & deltaPhi() const
deltaPhi at pre sampler(0) -> 3rd sampling(3)
void setDeltaPhi(const std::array< double, 4 > &deltaPhis)
set Phi of track extrapolated at pre sampler(0) -> 3rd sampling(3)
void setVertices(const std::vector< ElementLink< xAOD::VertexContainer > > &links)
set Pointer to the xAOD::vertex/vertices that match the photon candidate
float m_deltaEtaVtx
Definition egammaRec.h:155
ElementLink< xAOD::VertexContainer > vertexElementLink(size_t index=0) const
ElementLink to the xAOD::vertex/es that match the electron candidate.
Definition egammaRec.cxx:63
const xAOD::CaloCluster * caloCluster(size_t index=0) const
Pointer to the xAOD::CaloCluster/s that define the electron candidate.
Definition egammaRec.cxx:8
egammaRec & operator=(const egammaRec &)=default
void setDeltaEtaVtx(float value)
set deltaEtaVtx
egammaRec(egammaRec &&)=default
const xAOD::TrackParticle * trackParticle(size_t index=0) const
Pointer to the xAOD::TrackParticle/s that match the electron candidate.
Definition egammaRec.cxx:31
ElementLink< xAOD::TrackParticleContainer > trackParticleElementLink(size_t index=0) const
ElementLink to the xAOD::TrackParticle/s that match the electron candidate.
Definition egammaRec.cxx:40
float m_deltaPhiVtx
Definition egammaRec.h:156
size_t getNumberOfVertices() const
Return the number xAOD::Vertex/vertices that match the photon candidate.
ElementLink< xAOD::CaloClusterContainer > caloClusterElementLink(size_t index=0) const
ElementLink to the xAOD::CaloCluster/s that match the electron candidate.
Definition egammaRec.cxx:17
Definition index.py:1
CaloCluster_v1 CaloCluster
Define the latest version of the calorimeter cluster class.
TrackParticle_v1 TrackParticle
Reference the current persistent version:
Vertex_v1 Vertex
Define the latest version of the vertex class.