ATLAS Offline Software
DeltaRTool.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef DERIVATIONFRAMEWORK_DELTARTOOL_H
6 #define DERIVATIONFRAMEWORK_DELTARTOOL_H
7 
8 
9 
16 
17 #include <vector>
18 #include <string>
19 class EventContext;
20 
21 namespace DerivationFramework {
22 
24  class DeltaRTool : public extends<ExpressionParserUser<AthAlgTool,kDeltaRToolParserNum>, IAugmentationTool> {
25  public:
26  DeltaRTool(const std::string& t, const std::string& n, const IInterface* p);
27 
30  virtual StatusCode addBranches(const EventContext& ctx) const;
31 
32  private:
33  std::string m_expression;
34  std::string m_2ndExpression;
35  SG::WriteHandleKey<std::vector<float> > m_sgName {this,"StoreGateEntryName","","SG key of output object"};
36  SG::ReadHandleKey<xAOD::IParticleContainer> m_containerName {this,"ContainerName","","SG key of first container"};
37  SG::ReadHandleKey<xAOD::IParticleContainer> m_containerName2 {this,"SecondContainerName","","SG key of first container"};
38 
39  StatusCode getDeltaRs(std::vector<float>*, const EventContext& ctx) const;
40  static float calculateDeltaR(float,float,float,float) ;
41  };
42 }
43 
44 #endif // DERIVATIONFRAMEWORK_DELTARTOOL_H
DerivationFramework::kDeltaRToolParser1
@ kDeltaRToolParser1
Definition: DeltaRTool.h:23
ReadHandleKey.h
Property holding a SG store/key/clid from which a ReadHandle is made.
DerivationFramework::kDeltaRToolParserNum
@ kDeltaRToolParserNum
Definition: DeltaRTool.h:23
DerivationFramework::DeltaRTool::m_containerName
SG::ReadHandleKey< xAOD::IParticleContainer > m_containerName
Definition: DeltaRTool.h:36
DerivationFramework::DeltaRTool::m_2ndExpression
std::string m_2ndExpression
Definition: DeltaRTool.h:34
IAugmentationTool.h
ExpressionParserUser.h
DerivationFramework::DeltaRTool::m_containerName2
SG::ReadHandleKey< xAOD::IParticleContainer > m_containerName2
Definition: DeltaRTool.h:37
DerivationFramework::DeltaRTool::initialize
StatusCode initialize()
Definition: DeltaRTool.cxx:23
DerivationFramework::DeltaRTool::m_expression
std::string m_expression
Definition: DeltaRTool.h:33
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
SG::ReadHandleKey
Property holding a SG store/key/clid from which a ReadHandle is made.
Definition: StoreGate/StoreGate/ReadHandleKey.h:39
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:209
DerivationFramework::DeltaRTool::calculateDeltaR
static float calculateDeltaR(float, float, float, float)
Definition: DeltaRTool.cxx:156
DerivationFramework::DeltaRTool::DeltaRTool
DeltaRTool(const std::string &t, const std::string &n, const IInterface *p)
Definition: DeltaRTool.cxx:12
SG::WriteHandleKey
Property holding a SG store/key/clid from which a WriteHandle is made.
Definition: StoreGate/StoreGate/WriteHandleKey.h:40
beamspotman.n
n
Definition: beamspotman.py:727
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
IParticleContainer.h
AthAlgTool.h
DerivationFramework
THE reconstruction tool.
Definition: ParticleSortingAlg.h:24
DerivationFramework::DeltaRTool::addBranches
virtual StatusCode addBranches(const EventContext &ctx) const
Definition: DeltaRTool.cxx:46
DerivationFramework::DeltaRTool::getDeltaRs
StatusCode getDeltaRs(std::vector< float > *, const EventContext &ctx) const
Definition: DeltaRTool.cxx:62
WriteHandleKey.h
Property holding a SG store/key/clid from which a WriteHandle is made.
DerivationFramework::kDeltaRToolParser2
@ kDeltaRToolParser2
Definition: DeltaRTool.h:23
DerivationFramework::EDeltaRToolParser
EDeltaRToolParser
Definition: DeltaRTool.h:23
DerivationFramework::DeltaRTool::m_sgName
SG::WriteHandleKey< std::vector< float > > m_sgName
Definition: DeltaRTool.h:35
DerivationFramework::DeltaRTool
Definition: DeltaRTool.h:24
DerivationFramework::DeltaRTool::finalize
StatusCode finalize()
Definition: DeltaRTool.cxx:40