ATLAS Offline Software
Loading...
Searching...
No Matches
InvariantMassTool.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_INVARIANTMASSTOOL_H
6#define DERIVATIONFRAMEWORK_INVARIANTMASSTOOL_H
7
8
11
17#include <string>
18#include <vector>
19
20class TVector3;
21class EventContext;
22
23namespace DerivationFramework {
24
26 class InvariantMassTool : public extends<ExpressionParserUser<AthAlgTool,kInvariantMassToolParserNum>, IAugmentationTool> {
27 public:
28
29 using base_class::base_class;
30
31 virtual StatusCode initialize() override final;
32 virtual StatusCode finalize() override final;
33 virtual StatusCode addBranches(const EventContext& ctx) const override final;
34
35 private:
36 Gaudi::Property<std::string> m_expression{this, "ObjectRequirements", "true"};
37 Gaudi::Property<std::string> m_expression2{this, "SecondObjectRequirements", ""};
38 SG::WriteHandleKey<std::vector<float> > m_sgName {this,"StoreGateEntryName","","SG key of output object"};
39 Gaudi::Property<float> m_massHypothesis{this, "MassHypothesis", 0.0};
40 Gaudi::Property<float> m_massHypothesis2{this, "SecondMassHypothesis", 2.0};
41 SG::ReadHandleKey<xAOD::IParticleContainer> m_containerName {this,"ContainerName","","SG key of first container"};
42 SG::ReadHandleKey<xAOD::IParticleContainer> m_containerName2 {this,"SecondContainerName","","SG key of second container"};
43 SG::ReadDecorHandleKeyArray<xAOD::IParticleContainer> m_inputDecorNames {this, "InputDecorNames",{},"SG keys for decorations of first (and second) container(s)"};
44 StatusCode getInvariantMasses(std::vector<float>*, const EventContext& ctx) const;
45 static float calculateInvariantMass(const TVector3& v1, const TVector3&v2,float M1,float M2) ;
46 };
47}
48
49#endif // DERIVATIONFRAMEWORK_INVARIANTMASSTOOL_H
Property holding a SG store/key/clid from which a ReadHandle is made.
Property holding a SG store/key/clid from which a WriteHandle is made.
Gaudi::Property< float > m_massHypothesis
SG::ReadDecorHandleKeyArray< xAOD::IParticleContainer > m_inputDecorNames
SG::ReadHandleKey< xAOD::IParticleContainer > m_containerName
Gaudi::Property< float > m_massHypothesis2
virtual StatusCode finalize() override final
virtual StatusCode initialize() override final
Gaudi::Property< std::string > m_expression2
SG::ReadHandleKey< xAOD::IParticleContainer > m_containerName2
SG::WriteHandleKey< std::vector< float > > m_sgName
static float calculateInvariantMass(const TVector3 &v1, const TVector3 &v2, float M1, float M2)
Gaudi::Property< std::string > m_expression
virtual StatusCode addBranches(const EventContext &ctx) const override final
StatusCode getInvariantMasses(std::vector< float > *, const EventContext &ctx) const
Property holding a SG store/key/clid from which a ReadHandle is made.
Property holding a SG store/key/clid from which a WriteHandle is made.
THE reconstruction tool.
DecorHandleKeyArray< ReadDecorHandle< T, S >, ReadDecorHandleKey< T >, Gaudi::DataHandle::Reader > ReadDecorHandleKeyArray