ATLAS Offline Software
Loading...
Searching...
No Matches
MuonSegment_v1.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
5
6// EDM include(s):
8
9// Local include(s):
11
12namespace xAOD {
13
14
16 return Amg::Vector3D{x(), y(), z()};
17 }
19 return Amg::Vector3D{px(), py(), pz()};
20 }
21
25
26 void MuonSegment_v1::setPosition(float x, float y, float z) {
27 static const Accessor< float > acc1( "x" );
28 acc1( *this ) = x;
29 static const Accessor< float > acc2( "y" );
30 acc2( *this ) = y;
31 static const Accessor< float > acc3( "z" );
32 acc3( *this ) = z;
33 }
34
38
39 void MuonSegment_v1::setDirection(float px, float py, float pz) {
40 static const Accessor< float > acc1( "px" );
41 acc1( *this ) = px;
42 static const Accessor< float > acc2( "py" );
43 acc2( *this ) = py;
44 static const Accessor< float > acc3( "pz" );
45 acc3( *this ) = pz;
46 }
47
50
51 void MuonSegment_v1::setT0Error(float t0, float t0error) {
52 static const Accessor< float > acc1( "t0" );
53 acc1( *this ) = t0;
54 static const Accessor< float > acc2( "t0error" );
55 acc2( *this ) = t0error;
56 }
57
58 AUXSTORE_PRIMITIVE_GETTER( MuonSegment_v1, float, chiSquared )
59 AUXSTORE_PRIMITIVE_GETTER( MuonSegment_v1, float, numberDoF )
60
62 static const Accessor< float > acc1( "chiSquared" );
63 acc1( *this ) = chiSquared;
64 static const Accessor< float > acc2( "numberDoF" );
65 acc2( *this ) = numberDoF;
66 }
67
72
73 void MuonSegment_v1::setIdentifier(int sector, Muon::MuonStationIndex::ChIndex chamberIndex, int etaIndex, Muon::MuonStationIndex::TechnologyIndex technology) {
74 static const Accessor< int > acc1( "sector" );
75 acc1( *this ) = sector;
76 static const Accessor< int > acc2( "chamberIndex" );
77 acc2( *this ) = static_cast<int>(chamberIndex);
78 static const Accessor< int > acc3( "etaIndex" );
79 acc3( *this ) = etaIndex;
80 static const Accessor< int > acc4( "technology" );
81 acc4( *this ) = static_cast<int>(technology);
82 }
83
84 AUXSTORE_PRIMITIVE_GETTER( MuonSegment_v1, int , nPrecisionHits )
85 AUXSTORE_PRIMITIVE_GETTER( MuonSegment_v1, int , nPhiLayers )
86 AUXSTORE_PRIMITIVE_GETTER( MuonSegment_v1, int , nTrigEtaLayers )
87
89 static const Accessor< int > acc1( "nPrecisionHits" );
90 acc1( *this ) = nPrecisionHits;
91 static const Accessor< int > acc2( "nPhiLayers" );
92 acc2( *this ) = nPhiLayers;
93 static const Accessor< int > acc3( "nTrigEtaLayers" );
94 acc3( *this ) = nTrigEtaLayers;
95 }
96
97 #if !(defined(GENERATIONBASE) || defined(XAOD_ANALYSIS))
99 #endif // not XAOD_ANALYSIS or GENERATIONBASE
100
101} // namespace xAOD
#define AUXSTORE_PRIMITIVE_GETTER_WITH_CAST(CL, PERSTYPE, TRANSTYPE, NAME)
Macro creating a getter function with a type conversion.
#define AUXSTORE_PRIMITIVE_GETTER(CL, TYPE, NAME)
Macro creating the reader function for a primitive auxiliary property.
#define AUXSTORE_OBJECT_SETTER_AND_GETTER(CL, TYPE, NAME, SETTER)
Macro creating the accessors of complex auxiliary properties.
static Double_t t0
#define y
#define x
#define z
SG::Accessor< T, ALLOC > Accessor
Definition AuxElement.h:572
Class describing a MuonSegment.
void setDirection(float px, float py, float pz)
Sets the direction.
float px() const
float y() const
Returns the x position.
float pz() const
Returns the pz.
float t0() const
int nTrigEtaLayers() const
Returns the number of trigger eta layers.
float numberDoF() const
Returns the numberDoF.
MuonSegment_v1()=default
Default constructor.
void setFitQuality(float chiSquared, float numberDoF)
Set the 'Fit Quality' information.
void setNHits(int nPrecisionHits, int nPhiLayers, int nTrigEtaLayers)
Set the number of hits/layers.
int nPrecisionHits() const
Amg::Vector3D direction() const
Returns the direction as Amg::Vector.
void setT0Error(float t0, float t0Error)
Sets the time error.
void setIdentifier(int sector, ::Muon::MuonStationIndex::ChIndex chamberIndex, int etaIndex, ::Muon::MuonStationIndex::TechnologyIndex technology)
Set the identifier.
float chiSquared() const
float py() const
Returns the py.
void setPosition(float x, float y, float z)
Sets the global position.
::Muon::MuonStationIndex::TechnologyIndex technology() const
Returns the main technology of the segment.
::Muon::MuonStationIndex::ChIndex chamberIndex() const
Returns the chamber index.
Amg::Vector3D position() const
Returns the position as Amg::Vector.
int nPhiLayers() const
Returns the number of phi layers.
int etaIndex() const
Returns the eta index, which corresponds to stationEta in the offline identifiers (and the ).
float t0error() const
Returns the time error.
float z() const
Returns the y position.
Eigen::Matrix< double, 3, 1 > Vector3D
TechnologyIndex
enum to classify the different 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.
ICaloAffectedTool is abstract interface for tools checking if 4 mom is in calo affected region.