ATLAS Offline Software
Loading...
Searching...
No Matches
MissingET_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 XAODMISSINGET_VERSIONS_MISSINGET_V1_H
8#define XAODMISSINGET_VERSIONS_MISSINGET_V1_H
9
11
13
14#include "xAODBase/IParticle.h"
16
17#include <string>
18#include <functional>
19#include <utility>
20
21namespace xAOD
22{
25 {
26 public:
27
30 explicit MissingET_v1(bool createStore=false);
31 MissingET_v1(const std::string& name,
33 MissingET_v1(const IParticle* particle, const std::string& name="MissingET",
35 MissingET_v1(float mpx,float mpy,float sumet,const std::string& name="MissingET",
40
43 float mpx() const;
44 float mpy() const;
45 float met() const;
46 float phi() const;
47 float sumet() const;
49
52 void setMpx(float value);
53 void setMpy(float value);
54 void setSumet(float value);
56
59 const std::string& name() const;
61 std::size_t nameHash() const;
63
66 void setName(const std::string& name);
68 void updateHash();
70
73 void add(const IParticle* particle);
74 void add(const IParticle* particle,float scale);
75 void add(float px,float py,float pt);
77 MissingET_v1& operator+=(const IParticle* particle);
78 MissingET_v1& operator-=(const IParticle* part);
80
85 MissingET_v1& operator*=(float scale);
86 MissingET_v1& operator/=(float scale);
88
91 void clear();
93
96 bool operator==(const MissingET_v1& met) const;
97 bool operator!=(const MissingET_v1& met) const;
99
100
101
102 protected:
104 void createPrivateStore();
105
108 float& f_mpx();
109 float& f_mpy();
110 float& f_sumet();
111 std::string& f_name();
112 const std::string& f_nameConst() const;
115
116 private:
118
122 };
123}
124
135
137
138#endif
Base class for elements of a container that can have aux data.
Cached value with atomic update.
xAOD::MissingET_v1 operator+(const xAOD::MissingET_v1 &met0, const xAOD::MissingET_v1 &met1)
Create new MET object from sum of two MissingET_v1 objects.
xAOD::MissingET_v1 operator/(const xAOD::MissingET_v1 &met, float scale)
Create new MET object from source with scaled kinematics.
xAOD::MissingET_v1 operator-(const xAOD::MissingET_v1 &met0, const xAOD::MissingET_v1 &met1)
Create new MET object from difference between two MissingET_v1 objects.
xAOD::MissingET_v1 operator*(const xAOD::MissingET_v1 &met, float scale)
Create new MET object from source with scaled (weighted) kinematics.
Cached value with atomic update.
Definition CachedValue.h:55
Base class for elements of a container that can have aux data.
Definition AuxElement.h:483
SG::Accessor< T, ALLOC > Accessor
Definition AuxElement.h:572
Class providing the definition of the 4-vector interface.
Principal data object for Missing ET.
void setMpy(float value)
Set the component.
float sumet() const
Returns.
MissingET_v1 & operator-=(const IParticle *part)
Remove particle kinematics to MET.
MissingET_v1 & operator+=(const IParticle *particle)
Add particle kinematics to MET.
void clear()
Clear/reset the data store.
CxxUtils::CachedValue< std::size_t > m_nameHash
Stores the hash for the current f_name string.
bool operator==(const MissingET_v1 &met) const
Equality test.
MissingET_v1 & operator-=(const MissingET_v1 &met)
Subtract another MET object.
void add(const IParticle *particle)
Add particle kinematics to MET.
const std::string & f_nameConst() const
Returns const reference to the MET object name store.
MissingET_v1 & operator/=(float scale)
Dividing by a scale factor.
MissingETBase::Types::bitmask_t source() const
MET object source tag.
MissingETBase::Types::bitmask_t & f_source()
Returns reference to MET object source store.
void setSource(MissingETBase::Types::bitmask_t src)
Set the source of the MET object.
float met() const
Returns .
float & f_mpy()
Returns reference to store.
~MissingET_v1()
Implementation class destructor.
void createPrivateStore()
Function initialising the object to work in standalone mode.
static const SG::AuxElement::Accessor< float > m_acc_mpy
void updateHash()
Update the hash to match the current name.
std::size_t nameHash() const
Return hash associated to the MET object name.
MissingET_v1(bool createStore=false)
Default constructor.
static const SG::AuxElement::Accessor< float > m_acc_sumet
float & f_mpx()
Returns reference to store.
std::string & f_name()
Returns reference to MET object name store.
float phi() const
Returns .
bool operator!=(const MissingET_v1 &met) const
Inequality test.
MissingET_v1 & operator*=(float scale)
Applying a scale factor.
void setMpx(float value)
Set the component.
const std::string & name() const
Identifier getters.
float mpx() const
Returns .
MissingET_v1 & operator=(const MissingET_v1 &met)
Add particle kinematics to MET.
static const SG::AuxElement::Accessor< float > m_acc_mpx
MissingET_v1 & operator+=(const MissingET_v1 &met)
Add another MET object.
void setName(const std::string &name)
Set the name of the MET object.
float & f_sumet()
Returns reference to store.
float mpy() const
Returns .
void setSumet(float value)
Set .
uint64_t bitmask_t
Type for status word bit mask.
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.
setRcore setEtHad setFside pt
static Types::bitmask_t unknown()