ATLAS Offline Software
Loading...
Searching...
No Matches
MuonCombined::InDetCandidate Class Reference

#include <InDetCandidate.h>

Collaboration diagram for MuonCombined::InDetCandidate:

Public Member Functions

 InDetCandidate (const xAOD::TrackParticle &idTrack)
 constructor taking a xAOD::TrackParicle& Users should ensure that the lifetime of the idTrack object is longer than the InDetCandidate as it internally caches a pointer to it.
 InDetCandidate (const ElementLink< xAOD::TrackParticleContainer > &idTrackLink)
 constructor taking an ElementLink to a xAOD::TrackParicle& Users should ensure that the element link is valid and the lifetime of the idTrack object is longer than the InDetCandidate as it internally caches a pointer to it.
bool operator== (const InDetCandidate &other) const
 Define two InDetCandidates to be equal if they are built from the same track.
 ~InDetCandidate ()
 destructor
const xAOD::TrackParticleindetTrackParticle () const
 access TrackParticle
const ElementLink< xAOD::TrackParticleContainer > & indetTrackParticleLink () const
 access TrackParticleLink
const Muon::MuonSystemExtensiongetExtension () const
const Trk::CaloExtensiongetCaloExtension () const
void setExtension (std::unique_ptr< Muon::MuonSystemExtension > extension)
void setExtension (std::unique_ptr< Trk::CaloExtension > &extension)
 set CaloExtension
void setExtension (const Trk::CaloExtension *extension)
bool isSiliconAssociated () const
 Returns true if this candidate was formed from a special far forward InDet track.
void setSiliconAssociated (bool)
 Pass true if this candiate was created from a special far forward InDet track.
std::string toString () const
 print candidate to string

Private Attributes

ElementLink< xAOD::TrackParticleContainerm_idTrackParticleLink
 ElementLink to the InDet TrackParticle.
const xAOD::TrackParticlem_idTrackParticle {nullptr}
 cached pointer to the InDet TrackParticle
bool m_siAssociated {false}
 Was this created using a special far forward indet track.
std::unique_ptr< Muon::MuonSystemExtensionm_extension {nullptr}
std::unique_ptr< Trk::CaloExtensionm_calo_extension {nullptr}
const Trk::CaloExtensionm_calo_extension_ptr {nullptr}

Detailed Description

Definition at line 18 of file InDetCandidate.h.

Constructor & Destructor Documentation

◆ InDetCandidate() [1/2]

MuonCombined::InDetCandidate::InDetCandidate ( const xAOD::TrackParticle & idTrack)

constructor taking a xAOD::TrackParicle& Users should ensure that the lifetime of the idTrack object is longer than the InDetCandidate as it internally caches a pointer to it.

Definition at line 11 of file InDetCandidate.cxx.

11: m_idTrackParticle{&idTrack} {}
const xAOD::TrackParticle * m_idTrackParticle
cached pointer to the InDet TrackParticle

◆ InDetCandidate() [2/2]

MuonCombined::InDetCandidate::InDetCandidate ( const ElementLink< xAOD::TrackParticleContainer > & idTrackLink)

constructor taking an ElementLink to a xAOD::TrackParicle& Users should ensure that the element link is valid and the lifetime of the idTrack object is longer than the InDetCandidate as it internally caches a pointer to it.

Definition at line 13 of file InDetCandidate.cxx.

ElementLink< xAOD::TrackParticleContainer > m_idTrackParticleLink
ElementLink to the InDet TrackParticle.
setStrategy setMatchFlag idTrackLink

◆ ~InDetCandidate()

MuonCombined::InDetCandidate::~InDetCandidate ( )
default

destructor

Member Function Documentation

◆ getCaloExtension()

const Trk::CaloExtension * MuonCombined::InDetCandidate::getCaloExtension ( ) const

Definition at line 47 of file InDetCandidate.cxx.

47{ return m_calo_extension_ptr; }
const Trk::CaloExtension * m_calo_extension_ptr

◆ getExtension()

const Muon::MuonSystemExtension * MuonCombined::InDetCandidate::getExtension ( ) const

Definition at line 46 of file InDetCandidate.cxx.

46{ return m_extension.get(); }
std::unique_ptr< Muon::MuonSystemExtension > m_extension

◆ indetTrackParticle()

const xAOD::TrackParticle & MuonCombined::InDetCandidate::indetTrackParticle ( ) const

access TrackParticle

Definition at line 27 of file InDetCandidate.cxx.

27 {
28 if (!m_idTrackParticleLink.isValid()) {}
29 return **m_idTrackParticleLink;
30 return *m_idTrackParticle;
31 }

◆ indetTrackParticleLink()

const ElementLink< xAOD::TrackParticleContainer > & MuonCombined::InDetCandidate::indetTrackParticleLink ( ) const

access TrackParticleLink

Definition at line 33 of file InDetCandidate.cxx.

33{ return m_idTrackParticleLink; }

◆ isSiliconAssociated()

bool MuonCombined::InDetCandidate::isSiliconAssociated ( ) const

Returns true if this candidate was formed from a special far forward InDet track.

Definition at line 35 of file InDetCandidate.cxx.

35{ return m_siAssociated; }
bool m_siAssociated
Was this created using a special far forward indet track.

◆ operator==()

bool MuonCombined::InDetCandidate::operator== ( const InDetCandidate & other) const

Define two InDetCandidates to be equal if they are built from the same track.

Definition at line 49 of file InDetCandidate.cxx.

49{ return &other.indetTrackParticle() == &indetTrackParticle(); }
const xAOD::TrackParticle & indetTrackParticle() const
access TrackParticle

◆ setExtension() [1/3]

void MuonCombined::InDetCandidate::setExtension ( const Trk::CaloExtension * extension)

Definition at line 44 of file InDetCandidate.cxx.

44{ m_calo_extension_ptr = extension; }

◆ setExtension() [2/3]

void MuonCombined::InDetCandidate::setExtension ( std::unique_ptr< Muon::MuonSystemExtension > extension)

Definition at line 39 of file InDetCandidate.cxx.

39{ m_extension = std::move(extension); }

◆ setExtension() [3/3]

void MuonCombined::InDetCandidate::setExtension ( std::unique_ptr< Trk::CaloExtension > & extension)

set CaloExtension

Definition at line 40 of file InDetCandidate.cxx.

40 {
41 m_calo_extension = std::move(extension);
43 }
std::unique_ptr< Trk::CaloExtension > m_calo_extension

◆ setSiliconAssociated()

void MuonCombined::InDetCandidate::setSiliconAssociated ( bool value)

Pass true if this candiate was created from a special far forward InDet track.

Definition at line 37 of file InDetCandidate.cxx.

◆ toString()

std::string MuonCombined::InDetCandidate::toString ( ) const

print candidate to string

Definition at line 17 of file InDetCandidate.cxx.

17 {
18 std::ostringstream sout;
19 sout << " pt: " << indetTrackParticle().pt() * 1.e-3 << " GeV, eta: " << indetTrackParticle().eta()
20 << ", phi: " << indetTrackParticle().phi();
21 sout << ", d0: " << indetTrackParticle().d0() << ", z0: " << indetTrackParticle().z0() << ", q: " << indetTrackParticle().charge()
22 << " ";
23 if (isSiliconAssociated()) sout << " is SAF.";
24 return sout.str();
25 }
bool isSiliconAssociated() const
Returns true if this candidate was formed from a special far forward InDet track.
float z0() const
Returns the parameter.
virtual double phi() const override final
The azimuthal angle ( ) of the particle (has range to .)
float d0() const
Returns the parameter.
virtual double pt() const override final
The transverse momentum ( ) of the particle.
virtual double eta() const override final
The pseudorapidity ( ) of the particle.
float charge() const
Returns the charge.

Member Data Documentation

◆ m_calo_extension

std::unique_ptr<Trk::CaloExtension> MuonCombined::InDetCandidate::m_calo_extension {nullptr}
private

Definition at line 74 of file InDetCandidate.h.

74{nullptr};

◆ m_calo_extension_ptr

const Trk::CaloExtension* MuonCombined::InDetCandidate::m_calo_extension_ptr {nullptr}
private

Definition at line 75 of file InDetCandidate.h.

75{nullptr};

◆ m_extension

std::unique_ptr<Muon::MuonSystemExtension> MuonCombined::InDetCandidate::m_extension {nullptr}
private

Definition at line 73 of file InDetCandidate.h.

73{nullptr};

◆ m_idTrackParticle

const xAOD::TrackParticle* MuonCombined::InDetCandidate::m_idTrackParticle {nullptr}
private

cached pointer to the InDet TrackParticle

Definition at line 68 of file InDetCandidate.h.

68{nullptr};

◆ m_idTrackParticleLink

ElementLink<xAOD::TrackParticleContainer> MuonCombined::InDetCandidate::m_idTrackParticleLink
private

ElementLink to the InDet TrackParticle.

Definition at line 65 of file InDetCandidate.h.

◆ m_siAssociated

bool MuonCombined::InDetCandidate::m_siAssociated {false}
private

Was this created using a special far forward indet track.

Definition at line 71 of file InDetCandidate.h.

71{false};

The documentation for this class was generated from the following files: