ATLAS Offline Software
Loading...
Searching...
No Matches
MuPatSegment.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#ifndef MUPATSEGMENT_H
6#define MUPATSEGMENT_H
7
8#include <mutex>
9#include <set>
10
11#include "Identifier/Identifier.h"
17
18namespace Muon {
19
20 class MuPatTrack;
21
42
43 class MuPatSegment : public MuPatCandidateBase, public Trk::ObjectCounter<MuPatSegment> {
44 public:
47 MuPatSegment() = default;
48 ~MuPatSegment() = default;
49
50
51 int quality{0};
53 const MuonSegment* segment{nullptr};
54 std::shared_ptr<const Trk::AtaPlane> segPars{nullptr};
55 int segmentIndex{-1};
56 int usedInFit{0};
58 std::string name{};
59 ChIdx chIndex{ChIdx::ChUnknown};
60 StIdx stIndex{StIdx::StUnknown};
61 bool isEndcap{false};
62 bool isMdt{false};
63
65 const Trk::TrackParameters& entryPars() const;
66
68 void addTrack(MuPatTrack*);
69
72
74 const std::set<MuPatTrack*>& tracks() const { return m_associatedTracks; }
75
76 private:
77 std::set<MuPatTrack*> m_associatedTracks; //<! list of associated tracks
78
79 }; // class MuPatSegment
80
81 //
82 // inline member functions implementations
83 //
84 inline const Trk::TrackParameters& MuPatSegment::entryPars() const { return *segPars; }
85
87 bool operator()(const MuPatSegment* c1, const MuPatSegment* c2) { return operator()(*c1, *c2); }
88 bool operator()(const MuPatSegment& c1, const MuPatSegment& c2) {
89 return c1.segment->globalPosition().perp() < c2.segment->globalPosition().perp();
90 }
91 };
93 bool operator()(const MuPatSegment* c1, const MuPatSegment* c2) { return operator()(*c1, *c2); }
94 bool operator()(const MuPatSegment& c1, const MuPatSegment& c2) {
95 return fabs(c1.segment->globalPosition().z()) < fabs(c2.segment->globalPosition().z());
96 }
97 };
99 bool operator()(const MuPatSegment* c1, const MuPatSegment* c2) { return operator()(*c1, *c2); }
100 bool operator()(const MuPatSegment& c1, const MuPatSegment& c2) { return c1.quality > c2.quality; }
101 };
102
103} // namespace Muon
104
105#endif
MuPatCandidateBase()=default
constructor.
segment candidate object.
~MuPatSegment()=default
void removeTrack(MuPatTrack *)
remove a track from the segment
std::set< MuPatTrack * > m_associatedTracks
const Trk::TrackParameters & entryPars() const
returns first track parameters
MuonStationIndex::StIndex StIdx
bool isMdt
true for MDT, false for CSC
MuPatSegment()=default
MuonStationIndex::ChIndex ChIdx
const MuonSegment * segment
void addTrack(MuPatTrack *)
add a new track to the segment
const std::set< MuPatTrack * > & tracks() const
access to the tracks the segment is associated with
int segmentIndex
index of segment within station
const MuonSegmentQuality * segQuality
std::shared_ptr< const Trk::AtaPlane > segPars
track candidate object.
Definition MuPatTrack.h:37
This is the common muon segment quality object.
This is the common class for 3D segments used in the muon spectrometer.
Helper to enable counting number of instantiations in debug builds.
StIndex
enum to classify the different station layers in the muon spectrometer
ChIndex
enum to classify the different chamber layers in the muon spectrometer
NRpcCablingAlg reads raw condition data and writes derived condition data to the condition store.
ParametersBase< TrackParametersDim, Charged > TrackParameters
bool operator()(const MuPatSegment *c1, const MuPatSegment *c2)
bool operator()(const MuPatSegment &c1, const MuPatSegment &c2)
bool operator()(const MuPatSegment *c1, const MuPatSegment *c2)
bool operator()(const MuPatSegment &c1, const MuPatSegment &c2)
bool operator()(const MuPatSegment &c1, const MuPatSegment &c2)
bool operator()(const MuPatSegment *c1, const MuPatSegment *c2)