ATLAS Offline Software
Loading...
Searching...
No Matches
JetManagerTool.h
Go to the documentation of this file.
1/*
2Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef Jet_Manager_H
6#define Jet_Manager_H
7
9
11#include "AsgTools/AsgTool.h"
12#include "AsgTools/ToolHandle.h"
16
23
25
26#include "TLorentzVector.h"
27#include <string>
28#include <vector>
29
30namespace Trig {
31
33 public asg::AsgTool {
35 public:
36 JetManagerTool(const std::string& name);
37 virtual ~JetManagerTool() = default;
38
39 virtual StatusCode initialize() override;
40
41 StatusCode retrieveByContainer(const EventContext& ctx,
42 EmulContext& emulCtx) const;
43
44 const std::string& jetContainerName() const;
45 const std::string& bjetContainerName() const;
46
47 const std::vector<TrigBtagEmulationJet>& getJets(const EmulContext& emulCtx) const;
48 const std::vector<TrigBtagEmulationJet>& getSortedPreselJets(const EmulContext& emulCtx) const;
49
50 private:
51 // These are set in the initialize method given JetContainerName
52 SG::ReadHandleKey< xAOD::JetContainer > m_jetInputKey {this, "InputJets", "", "Input Jet Collection Key, retrieved from reconstructed jets"};
53 SG::ReadHandleKey< xAOD::JetContainer > m_bjetInputKey {this, "InputBJets", "", "Input b-Jet Collection Key, retrieved from reconstructed jets"};
54 SG::ReadHandleKey< xAOD::BTaggingContainer > m_btagInputKey {this, "InputBTag", "HLT_xAOD__BTaggingContainer_HLTBjetFex", "Run2 input b-tag Collection Key"};
55
56 Gaudi::Property<std::string> m_btagging_link {this, "BTaggingLink", "btaggingLink"};
57 Gaudi::Property<std::string> m_jetcontainer {this, "JetContainerName", "", "Jet Container"};
58 Gaudi::Property<int> m_LHCPeriod {this, "LHCPeriod", 3, "LHC Period Run2 or Run3"};
59
60 bool matchedSPLITjet(const xAOD::Jet*, const xAOD::Jet*) const;
61 };
62
63 inline const std::string& JetManagerTool::jetContainerName() const { return m_jetInputKey.key(); }
64 inline const std::string& JetManagerTool::bjetContainerName() const { return m_bjetInputKey.key(); }
65} // namespace
66
67#endif
#define ASG_TOOL_CLASS0(CLASSNAME)
Property holding a SG store/key/clid from which a ReadHandle is made.
Defines enum to access jet attribute and associated particles/objects.
Property holding a SG store/key/clid from which a ReadHandle is made.
virtual ~JetManagerTool()=default
const std::string & jetContainerName() const
const std::vector< TrigBtagEmulationJet > & getSortedPreselJets(const EmulContext &emulCtx) const
const std::string & bjetContainerName() const
Gaudi::Property< int > m_LHCPeriod
SG::ReadHandleKey< xAOD::BTaggingContainer > m_btagInputKey
virtual StatusCode initialize() override
Dummy implementation of the initialisation function.
SG::ReadHandleKey< xAOD::JetContainer > m_jetInputKey
SG::ReadHandleKey< xAOD::JetContainer > m_bjetInputKey
JetManagerTool(const std::string &name)
bool matchedSPLITjet(const xAOD::Jet *, const xAOD::Jet *) const
const std::vector< TrigBtagEmulationJet > & getJets(const EmulContext &emulCtx) const
Gaudi::Property< std::string > m_jetcontainer
Gaudi::Property< std::string > m_btagging_link
StatusCode retrieveByContainer(const EventContext &ctx, EmulContext &emulCtx) const
Base class for the dual-use tool implementation classes.
Definition AsgTool.h:47
The common trigger namespace for trigger analysis tools.
Jet_v1 Jet
Definition of the current "jet version".