DataFormats
L1TMuon
src
L1MuBMTrackSegEta.cc
Go to the documentation of this file.
1
//-------------------------------------------------
2
//
3
// Class: L1MuBMTrackSegEta
4
//
5
// Description: ETA Track Segment
6
//
7
//
8
//
9
// Author :
10
// N. Neumeister CERN EP
11
//
12
//--------------------------------------------------
13
14
//-----------------------
15
// This Class's Header --
16
//-----------------------
17
18
#include "
DataFormats/L1TMuon/interface/L1MuBMTrackSegEta.h
"
19
20
//---------------
21
// C++ Headers --
22
//---------------
23
24
#include <iostream>
25
#include <iomanip>
26
#include <algorithm>
27
#include <bitset>
28
29
//-------------------------------
30
// Collaborating Class Headers --
31
//-------------------------------
32
33
#include "
DataFormats/L1TMuon/interface/BMTF/L1MuBMTrackSegLoc.h
"
34
35
using namespace
std
;
36
37
// --------------------------------
38
// class L1MuBMTrackSegEta
39
//---------------------------------
40
41
//----------------
42
// Constructors --
43
//----------------
44
45
L1MuBMTrackSegEta::L1MuBMTrackSegEta
() : m_location(), m_position(0), m_quality(0), m_bx(0) {}
46
47
L1MuBMTrackSegEta::L1MuBMTrackSegEta
(
int
wheel_id,
int
sector_id,
int
station_id,
int
pos
,
int
quality
,
int
bx
)
48
: m_location(wheel_id, sector_id, station_id), m_position(
pos
), m_quality(
quality
), m_bx(
bx
) {}
49
50
L1MuBMTrackSegEta::L1MuBMTrackSegEta
(
const
L1MuBMTrackSegLoc
&
id
,
int
pos
,
int
quality
,
int
bx
)
51
: m_location(
id
), m_position(
pos
), m_quality(
quality
), m_bx(
bx
) {}
52
53
L1MuBMTrackSegEta::L1MuBMTrackSegEta
(
const
L1MuBMTrackSegEta
&
id
)
54
: m_location(
id
.m_location), m_position(
id
.m_position), m_quality(
id
.m_quality), m_bx(
id
.m_bx) {}
55
56
//--------------
57
// Destructor --
58
//--------------
59
L1MuBMTrackSegEta::~L1MuBMTrackSegEta
() {}
60
61
//--------------
62
// Operations --
63
//--------------
64
65
//
66
// reset ETA Track Segment
67
//
68
void
L1MuBMTrackSegEta::reset
() {
69
m_position
= 0;
70
m_quality
= 0;
71
m_bx
= 0;
72
}
73
74
//
75
// Assignment operator
76
//
77
L1MuBMTrackSegEta
&
L1MuBMTrackSegEta::operator=
(
const
L1MuBMTrackSegEta
&
id
) {
78
if
(
this
!= &
id
) {
79
m_location
=
id
.m_location;
80
m_position
=
id
.m_position;
81
m_quality
=
id
.m_quality;
82
m_bx
=
id
.m_bx;
83
}
84
return
*
this
;
85
}
86
87
//
88
// Equal operator
89
//
90
bool
L1MuBMTrackSegEta::operator==
(
const
L1MuBMTrackSegEta
&
id
)
const
{
91
if
(
m_location
!=
id
.
m_location
)
92
return
false
;
93
if
(
m_position
!=
id
.
m_position
)
94
return
false
;
95
if
(
m_quality
!=
id
.
m_quality
)
96
return
false
;
97
if
(
m_bx
!=
id
.
m_bx
)
98
return
false
;
99
return
true
;
100
}
101
102
//
103
// Unequal operator
104
//
105
bool
L1MuBMTrackSegEta::operator!=
(
const
L1MuBMTrackSegEta
&
id
)
const
{
106
if
(
m_location
!=
id
.
m_location
)
107
return
true
;
108
if
(
m_position
!=
id
.
m_position
)
109
return
true
;
110
if
(
m_quality
!=
id
.
m_quality
)
111
return
true
;
112
if
(
m_bx
!=
id
.
m_bx
)
113
return
true
;
114
return
false
;
115
}
116
117
//
118
// output stream operator
119
//
120
ostream&
operator<<
(ostream&
s
,
const
L1MuBMTrackSegEta
&
id
) {
121
s
.setf(ios::right, ios::adjustfield);
122
s
<< (
id
.m_location) <<
"\t"
123
<<
"position : "
<< bitset<7>(
id
.
position
()) <<
" "
124
<<
"quality : "
<< bitset<7>(
id
.
quality
());
125
126
return
s
;
127
}
L1MuBMTrackSegEta::m_location
L1MuBMTrackSegLoc m_location
Definition:
L1MuBMTrackSegEta.h:98
L1MuBMTrackSegEta
Definition:
L1MuBMTrackSegEta.h:41
L1MuBMTrackSegEta::operator==
bool operator==(const L1MuBMTrackSegEta &) const
equal operator
Definition:
L1MuBMTrackSegEta.cc:90
L1MuBMTrackSegEta::m_position
unsigned int m_position
Definition:
L1MuBMTrackSegEta.h:99
pos
Definition:
PixelAliasList.h:18
l1GtPatternGenerator_cfi.bx
bx
Definition:
l1GtPatternGenerator_cfi.py:18
L1MuBMTrackSegEta::L1MuBMTrackSegEta
L1MuBMTrackSegEta()
default constructor
Definition:
L1MuBMTrackSegEta.cc:45
quality
const uint32_t *__restrict__ Quality * quality
Definition:
CAHitNtupletGeneratorKernelsImpl.h:109
alignCSCRings.s
s
Definition:
alignCSCRings.py:92
L1MuBMTrackSegEta::~L1MuBMTrackSegEta
virtual ~L1MuBMTrackSegEta()
destructor
Definition:
L1MuBMTrackSegEta.cc:59
L1MuBMTrackSegLoc.h
L1MuBMTrackSegLoc
Definition:
L1MuBMTrackSegLoc.h:41
L1MuBMTrackSegEta::operator=
L1MuBMTrackSegEta & operator=(const L1MuBMTrackSegEta &)
assignment operator
Definition:
L1MuBMTrackSegEta.cc:77
L1MuBMTrackSegEta::reset
void reset()
reset eta track segment
Definition:
L1MuBMTrackSegEta.cc:68
operator<<
ostream & operator<<(ostream &s, const L1MuBMTrackSegEta &id)
Definition:
L1MuBMTrackSegEta.cc:120
position
static int position[264][3]
Definition:
ReadPGInfo.cc:289
L1MuBMTrackSegEta::m_quality
unsigned int m_quality
Definition:
L1MuBMTrackSegEta.h:100
std
Definition:
JetResolutionObject.h:76
triggerObjects_cff.id
id
Definition:
triggerObjects_cff.py:29
L1MuBMTrackSegEta::operator!=
bool operator!=(const L1MuBMTrackSegEta &) const
unequal operator
Definition:
L1MuBMTrackSegEta.cc:105
L1MuBMTrackSegEta.h
L1MuBMTrackSegEta::m_bx
int m_bx
Definition:
L1MuBMTrackSegEta.h:101
Generated for CMSSW Reference Manual by
1.8.16