ATLAS Offline Software
Loading...
Searching...
No Matches
JetParticleAssociation.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3*/
4
5// author: cpollard@cern.ch
6
7#ifndef PARTICLEJETTOOLS_JETPARTICLEASSOCIATION_H
8#define PARTICLEJETTOOLS_JETPARTICLEASSOCIATION_H
9
10#include "AsgTools/AsgTool.h"
16
17#include <vector>
18#include <string>
19
20
22 virtual public IJetDecorator {
24
25 public:
26
27 JetParticleAssociation(const std::string& name);
28
29 virtual StatusCode initialize() override;
30 virtual StatusCode decorate(const xAOD::JetContainer& jets) const override;
31
32 // obvs to be provided by the deriving class
33 virtual const std::vector<std::vector<ElementLink<xAOD::IParticleContainer> > >*
35
36 private:
37
38 // note
39 // if m_particleKey is "", then an empty container will be written to the OutputDecoration.
40 Gaudi::Property<std::string> m_jetContainerName{this, "JetContainer", "", "Jet collection name"};
41 Gaudi::Property<float> m_ptMinimum{this, "MinimumJetPt", 0.0, "minimum pt to consider for association"};
42 SG::ReadHandleKey<xAOD::IParticleContainer> m_particleKey{this, "InputParticleContainer", "", "Input particle collection name"};
43 SG::WriteDecorHandleKey<xAOD::JetContainer> m_decKey{this, "OutputDecoration", "", "Output decoration name"};
44 SG::WriteDecorHandleKey<xAOD::JetContainer> m_passPtKey{this, "PassPtFlag", "", "Name for decoration indicating we passed pt threshold"};
45};
46
47#endif
#define ASG_TOOL_CLASS(CLASSNAME, INT1)
Interface for adding a decoration to a jet container.
SG::WriteDecorHandleKey< xAOD::JetContainer > m_decKey
virtual StatusCode decorate(const xAOD::JetContainer &jets) const override
Decorate a jet collection without otherwise modifying it.
SG::ReadHandleKey< xAOD::IParticleContainer > m_particleKey
Gaudi::Property< std::string > m_jetContainerName
virtual StatusCode initialize() override
Dummy implementation of the initialisation function.
Gaudi::Property< float > m_ptMinimum
SG::WriteDecorHandleKey< xAOD::JetContainer > m_passPtKey
virtual const std::vector< std::vector< ElementLink< xAOD::IParticleContainer > > > * match(const xAOD::JetContainer &, const xAOD::IParticleContainer &) const =0
JetParticleAssociation(const std::string &name)
Property holding a SG store/key/clid from which a ReadHandle is made.
Property holding a SG store/key/clid/attr name from which a WriteDecorHandle is made.
Base class for the dual-use tool implementation classes.
Definition AsgTool.h:47
JetContainer_v1 JetContainer
Definition of the current "jet container version".
DataVector< IParticle > IParticleContainer
Simple convenience declaration of IParticleContainer.