ATLAS Offline Software
Public Member Functions | Protected Attributes | List of all members
xAOD::JetAttributeAccessor::AccessorWrapper< JetFourMom_t > Class Reference

Specialiazed accessor for JetFourMom_t : internally stores the JetFourMom_t as 4 floats in the Aux Store. More...

#include <JetAccessors.h>

Inheritance diagram for xAOD::JetAttributeAccessor::AccessorWrapper< JetFourMom_t >:
Collaboration diagram for xAOD::JetAttributeAccessor::AccessorWrapper< JetFourMom_t >:

Public Member Functions

 AccessorWrapper ()
 
 AccessorWrapper (const std::string &name)
 
const floatpt (const SG::AuxElement &p) const
 
const floateta (const SG::AuxElement &p) const
 
const floatphi (const SG::AuxElement &p) const
 
const floatm (const SG::AuxElement &p) const
 
void setAttribute (SG::AuxElement &p, const JetFourMom_t &v) const
 
void getAttribute (const SG::AuxElement &p, JetFourMom_t &v) const
 
JetFourMom_t getAttribute (const SG::AuxElement &p) const
 
void setPtEtaPhiM (SG::AuxElement &p, float pt, float eta, float phi, float m)
 
bool isAvailable (const SG::AuxElement &e) const
 
std::string name () const
 

Protected Attributes

SG::AuxElement::Accessor< floatm_p0
 
SG::AuxElement::Accessor< floatm_p1
 
SG::AuxElement::Accessor< floatm_p2
 
SG::AuxElement::Accessor< floatm_p3
 
std::string m_name
 

Detailed Description

Specialiazed accessor for JetFourMom_t : internally stores the JetFourMom_t as 4 floats in the Aux Store.

Definition at line 156 of file JetAccessors.h.

Constructor & Destructor Documentation

◆ AccessorWrapper() [1/2]

Definition at line 158 of file JetAccessors.h.

158 : FourMomAccessor("_unnamed_","pt", "eta","phi", "m") {}

◆ AccessorWrapper() [2/2]

Definition at line 159 of file JetAccessors.h.

159 : FourMomAccessor(name, name+"_pt", name+"_eta",name+"_phi", name+"_m") {}

Member Function Documentation

◆ eta()

Definition at line 162 of file JetAccessors.h.

162 { return m_p1(p);}

◆ getAttribute() [1/2]

Definition at line 180 of file JetAccessors.h.

180  {
182  return v;
183  }

◆ getAttribute() [2/2]

void xAOD::JetAttributeAccessor::AccessorWrapper< JetFourMom_t >::getAttribute ( const SG::AuxElement p,
JetFourMom_t v 
) const
inline

Definition at line 173 of file JetAccessors.h.

173  {
174  v.SetPt( m_p0(p) );
175  v.SetEta( m_p1(p) );
176  v.SetPhi( m_p2(p) );
177  v.SetM( m_p3(p) );
178  }

◆ isAvailable()

bool xAOD::JetAttributeAccessor::FourMomAccessor::isAvailable ( const SG::AuxElement e) const
inlineinherited

Definition at line 143 of file JetAccessors.h.

143 {return m_p0.isAvailable(e);}

◆ m()

Definition at line 164 of file JetAccessors.h.

164 { return m_p3(p);}

◆ name()

std::string xAOD::JetAttributeAccessor::Named::name ( ) const
inlineinherited

Definition at line 43 of file JetAccessors.h.

43 {return m_name;}

◆ phi()

Definition at line 163 of file JetAccessors.h.

163 { return m_p2(p);}

◆ pt()

Definition at line 161 of file JetAccessors.h.

161 { return m_p0(p);}

◆ setAttribute()

void xAOD::JetAttributeAccessor::AccessorWrapper< JetFourMom_t >::setAttribute ( SG::AuxElement p,
const JetFourMom_t v 
) const
inline

Definition at line 166 of file JetAccessors.h.

166  {
167  m_p0(p) = v.Pt();
168  m_p1(p) = v.Eta();
169  m_p2(p) = v.Phi();
170  m_p3(p) = v.M();
171  }

◆ setPtEtaPhiM()

void xAOD::JetAttributeAccessor::AccessorWrapper< JetFourMom_t >::setPtEtaPhiM ( SG::AuxElement p,
float  pt,
float  eta,
float  phi,
float  m 
)
inline

Definition at line 186 of file JetAccessors.h.

186  {
187  m_p0(p) = pt ;
188  m_p1(p) = eta ;
189  m_p2(p) = phi ;
190  m_p3(p) = m ;
191  }

Member Data Documentation

◆ m_name

std::string xAOD::JetAttributeAccessor::Named::m_name
protectedinherited

Definition at line 45 of file JetAccessors.h.

◆ m_p0

SG::AuxElement::Accessor< float > xAOD::JetAttributeAccessor::FourMomAccessor::m_p0
protectedinherited

Definition at line 146 of file JetAccessors.h.

◆ m_p1

SG::AuxElement::Accessor< float > xAOD::JetAttributeAccessor::FourMomAccessor::m_p1
protectedinherited

Definition at line 147 of file JetAccessors.h.

◆ m_p2

SG::AuxElement::Accessor< float > xAOD::JetAttributeAccessor::FourMomAccessor::m_p2
protectedinherited

Definition at line 148 of file JetAccessors.h.

◆ m_p3

SG::AuxElement::Accessor< float > xAOD::JetAttributeAccessor::FourMomAccessor::m_p3
protectedinherited

Definition at line 149 of file JetAccessors.h.


The documentation for this class was generated from the following file:
xAOD::JetAttributeAccessor::Named::m_name
std::string m_name
Definition: JetAccessors.h:45
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
xAOD::JetAttributeAccessor::FourMomAccessor::m_p0
SG::AuxElement::Accessor< float > m_p0
Definition: JetAccessors.h:146
xAOD::JetAttributeAccessor::AccessorWrapper< JetFourMom_t >::m
const float & m(const SG::AuxElement &p) const
Definition: JetAccessors.h:164
xAOD::JetAttributeAccessor::Named::name
std::string name() const
Definition: JetAccessors.h:43
xAOD::JetAttributeAccessor::AccessorWrapper< JetFourMom_t >::phi
const float & phi(const SG::AuxElement &p) const
Definition: JetAccessors.h:163
xAOD::e
setPy e
Definition: CompositeParticle_v1.cxx:166
xAOD::JetAttributeAccessor::FourMomAccessor::m_p3
SG::AuxElement::Accessor< float > m_p3
Definition: JetAccessors.h:149
xAOD::JetFourMom_t
ROOT::Math::LorentzVector< ROOT::Math::PtEtaPhiM4D< double > > JetFourMom_t
Base 4 Momentum type for Jet.
Definition: JetTypes.h:17
xAOD::JetAttributeAccessor::AccessorWrapper< JetFourMom_t >::getAttribute
void getAttribute(const SG::AuxElement &p, JetFourMom_t &v) const
Definition: JetAccessors.h:173
python.PyAthena.v
v
Definition: PyAthena.py:157
xAOD::JetAttributeAccessor::AccessorWrapper< JetFourMom_t >::eta
const float & eta(const SG::AuxElement &p) const
Definition: JetAccessors.h:162
xAOD::JetAttributeAccessor::FourMomAccessor::m_p1
SG::AuxElement::Accessor< float > m_p1
Definition: JetAccessors.h:147
xAOD::JetAttributeAccessor::FourMomAccessor::m_p2
SG::AuxElement::Accessor< float > m_p2
Definition: JetAccessors.h:148
xAOD::JetAttributeAccessor::AccessorWrapper< JetFourMom_t >::pt
const float & pt(const SG::AuxElement &p) const
Definition: JetAccessors.h:161
xAOD::JetAttributeAccessor::FourMomAccessor::FourMomAccessor
FourMomAccessor(const std::string &name, const std::string &n0, const std::string &n1, const std::string &n2, const std::string &n3)
Definition: JetAccessors.h:140