ATLAS Offline Software
MuonTrackToSegmentTool.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 MUON_MUONTRACKTOSEGMENTTOOL_H
6 #define MUON_MUONTRACKTOSEGMENTTOOL_H
7 
8 #include <vector>
9 
11 #include "GaudiKernel/ServiceHandle.h"
12 #include "GaudiKernel/ToolHandle.h"
21 
22 namespace Trk {
23  class Track;
24  class MeasurementBase;
25 } // namespace Trk
26 
27 namespace Muon {
28  class MuonSegment;
29 }
30 
31 namespace Muon {
32 
42  public:
43  using MeasVec = std::vector<const Trk::MeasurementBase*>;
44 
46  MuonTrackToSegmentTool(const std::string&, const std::string&, const IInterface*);
47 
50 
53 
55  MuonSegment* convert(const EventContext& ctx, const Trk::Track& track) const;
56 
57  private:
59  std::vector<Identifier> calculateHoles(const EventContext& ctx, const Identifier& chid, const Trk::TrackParameters& pars,
60  const MeasVec& measurements) const;
61 
62 
63  ServiceHandle<Muon::IMuonIdHelperSvc> m_idHelperSvc{this, "MuonIdHelperSvc", "Muon::MuonIdHelperSvc/MuonIdHelperSvc"};
65  this, "edmHelper", "Muon::MuonEDMHelperSvc/MuonEDMHelperSvc",
66  "Handle to the service providing the IMuonEDMHelperSvc interface"}; //<! multipurpose helper tool
67 
68  PublicToolHandle<MuonEDMPrinterTool> m_printer{this, "EDMPrinter", "Muon::MuonEDMPrinterTool/MuonEDMPrinterTool",
69  "helper to nicely print out tracks"};
70  ToolHandle<Trk::IPropagator> m_propagator{this, "Propagator", "Trk::RungeKuttaPropagator/AtlasRungeKuttaPropagator"};
71 
72  SG::ReadCondHandleKey<Muon::MuonIntersectGeoData> m_chamberGeoKey{this, "ChamberGeoKey", "MuonStationIntersects", "Pointer to hole search service"};
73 
74  SG::ReadCondHandleKey<MuonGM::MuonDetectorManager> m_DetectorManagerKey{this, "DetectorManagerKey", "MuonDetectorManager",
75  "Key of input MuonDetectorManager condition data"};
76  };
77 
78 } // namespace Muon
79 
80 #endif
make_hlt_rep.pars
pars
Definition: make_hlt_rep.py:90
Muon::MuonTrackToSegmentTool::m_propagator
ToolHandle< Trk::IPropagator > m_propagator
Definition: MuonTrackToSegmentTool.h:70
TrackParameters.h
Trk::Track
The ATLAS Track class.
Definition: Tracking/TrkEvent/TrkTrack/TrkTrack/Track.h:73
MuonEDMPrinterTool.h
Muon::MuonTrackToSegmentTool::MuonTrackToSegmentTool
MuonTrackToSegmentTool(const std::string &, const std::string &, const IInterface *)
default AlgTool constructor
Definition: MuonTrackToSegmentTool.cxx:23
IPropagator.h
Muon
NRpcCablingAlg reads raw condition data and writes derived condition data to the condition store.
Definition: TrackSystemController.h:45
xAOD::MuonSegment
MuonSegment_v1 MuonSegment
Reference the current persistent version:
Definition: Event/xAOD/xAODMuon/xAODMuon/MuonSegment.h:13
MuonIntersectGeoData.h
Muon::MuonTrackToSegmentTool::convert
MuonSegment * convert(const EventContext &ctx, const Trk::Track &track) const
convert track to segment
Definition: MuonTrackToSegmentTool.cxx:37
Muon::MuonTrackToSegmentTool
Definition: MuonTrackToSegmentTool.h:41
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
AthAlgTool.h
Muon::MuonTrackToSegmentTool::m_chamberGeoKey
SG::ReadCondHandleKey< Muon::MuonIntersectGeoData > m_chamberGeoKey
Definition: MuonTrackToSegmentTool.h:72
Muon::MuonTrackToSegmentTool::m_printer
PublicToolHandle< MuonEDMPrinterTool > m_printer
Definition: MuonTrackToSegmentTool.h:68
Trk::ParametersBase
Definition: ParametersBase.h:55
Muon::MuonTrackToSegmentTool::~MuonTrackToSegmentTool
~MuonTrackToSegmentTool()=default
destructor
Muon::MuonTrackToSegmentTool::m_edmHelperSvc
ServiceHandle< IMuonEDMHelperSvc > m_edmHelperSvc
Definition: MuonTrackToSegmentTool.h:64
IMuonEDMHelperSvc.h
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
Muon::MuonTrackToSegmentTool::MeasVec
std::vector< const Trk::MeasurementBase * > MeasVec
Definition: MuonTrackToSegmentTool.h:43
Muon::IMuonTrackToSegmentTool
The IMuonSegmentMaker is a pure virtual interface for tools to find tracks starting from MuonSegmentC...
Definition: IMuonTrackToSegmentTool.h:23
MuonDetectorManager.h
SG::ReadCondHandleKey< Muon::MuonIntersectGeoData >
Muon::MuonTrackToSegmentTool::m_DetectorManagerKey
SG::ReadCondHandleKey< MuonGM::MuonDetectorManager > m_DetectorManagerKey
Definition: MuonTrackToSegmentTool.h:74
Muon::MuonTrackToSegmentTool::m_idHelperSvc
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Definition: MuonTrackToSegmentTool.h:63
IMuonTrackToSegmentTool.h
Track
Definition: TriggerChamberClusterOnTrackCreator.h:21
Muon::MuonTrackToSegmentTool::initialize
StatusCode initialize()
initialize method, method taken from bass-class AlgTool
Definition: MuonTrackToSegmentTool.cxx:27
xAOD::track
@ track
Definition: TrackingPrimitives.h:513
Muon::MuonSegment
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonSegment/MuonSegment/MuonSegment.h:45
AthAlgTool
Definition: AthAlgTool.h:26
IMuonIdHelperSvc.h
Muon::MuonTrackToSegmentTool::calculateHoles
std::vector< Identifier > calculateHoles(const EventContext &ctx, const Identifier &chid, const Trk::TrackParameters &pars, const MeasVec &measurements) const
calculate holes
Definition: MuonTrackToSegmentTool.cxx:211
ServiceHandle< Muon::IMuonIdHelperSvc >
Identifier
Definition: IdentifierFieldParser.cxx:14