CMS 3D CMS Logo

L1MuBMTrackSegPhi.h
Go to the documentation of this file.
1 //-------------------------------------------------
2 //
11 //
12 //--------------------------------------------------
13 #ifndef L1MUBM_TRACK_SEG_PHI_H
14 #define L1MUBM_TRACK_SEG_PHI_H
15 
16 //---------------
17 // C++ Headers --
18 //---------------
19 
20 #include <iosfwd>
21 #include <vector>
22 
23 //----------------------
24 // Base Class Headers --
25 //----------------------
26 
27 //------------------------------------
28 // Collaborating Class Declarations --
29 //------------------------------------
30 
32 
33 // ---------------------
34 // -- Class Interface --
35 // ---------------------
36 
38 
39 typedef std::vector<L1MuBMTrackSegPhi> L1MuBMTrackSegPhiCollection;
40 
42 public:
44  enum TSQuality { Li, Lo, Hi, Ho, LL, HL, HH, Null };
45 
48 
50  L1MuBMTrackSegPhi(int wheel_id,
51  int sector_id,
52  int station_id,
53  int phi = 0,
54  int phib = 0,
56  bool tag = false,
57  int bx = 17,
58  bool etaFlag = false);
59 
62  int phi = 0,
63  int phib = 0,
65  bool tag = false,
66  int bx = 17,
67  bool etaFlag = false);
68 
71 
73  virtual ~L1MuBMTrackSegPhi();
74 
76  void reset();
77 
79  double phiValue() const;
80 
82  double phibValue() const;
83 
85  inline int wheel() const { return m_location.wheel(); }
86 
88  inline int sector() const { return m_location.sector(); }
89 
91  inline int station() const { return m_location.station(); }
92 
94  inline const L1MuBMTrackSegLoc& where() const { return m_location; }
95 
97  inline int phi() const { return m_phi; }
98 
100  inline int phib() const { return m_phib; }
101 
103  inline int quality() const { return m_quality; }
104 
106  inline int tag() const { return m_tag; }
107 
109  inline int bx() const { return m_bx; }
110 
112  inline bool etaFlag() const { return m_etaFlag; }
113 
115  inline bool empty() const { return m_quality == Null; }
116 
118  inline void setEtaFlag(bool flag) { m_etaFlag = flag; }
119 
122 
124  bool operator==(const L1MuBMTrackSegPhi&) const;
125 
127  bool operator!=(const L1MuBMTrackSegPhi&) const;
128 
130  friend std::ostream& operator<<(std::ostream&, const TSQuality&);
131 
133  friend std::ostream& operator<<(std::ostream&, const L1MuBMTrackSegPhi&);
134 
135 private:
136  L1MuBMTrackSegLoc m_location; // logical location of TS
137  int m_phi; // 12 bits
138  int m_phib; // 10 bits
139  TSQuality m_quality; // 3 bits
140  bool m_tag; // tag for second TS (of chamber)
141  int m_bx; // bunch crossing identifier
142  bool m_etaFlag; // eta flag (for overlap region)
143 };
144 
145 #endif
L1MuBMTrackSegPhi::~L1MuBMTrackSegPhi
virtual ~L1MuBMTrackSegPhi()
destructor
Definition: L1MuBMTrackSegPhi.cc:94
L1MuBMTrackSegPhi::HL
Definition: L1MuBMTrackSegPhi.h:44
L1MuBMTrackSegLoc::station
int station() const
return station
Definition: L1MuBMTrackSegLoc.h:62
L1MuBMTrackSegPhi::station
int station() const
return station
Definition: L1MuBMTrackSegPhi.h:91
L1MuBMTrackSegPhi::operator!=
bool operator!=(const L1MuBMTrackSegPhi &) const
unequal operator
Definition: L1MuBMTrackSegPhi.cc:162
L1MuBMTrackSegPhi
Definition: L1MuBMTrackSegPhi.h:41
L1MuBMTrackSegPhi::m_location
L1MuBMTrackSegLoc m_location
Definition: L1MuBMTrackSegPhi.h:136
L1MuBMTrackSegPhi::m_phi
int m_phi
Definition: L1MuBMTrackSegPhi.h:137
L1MuBMTrackSegPhi::Li
Definition: L1MuBMTrackSegPhi.h:44
L1MuBMTrackSegPhi::bx
int bx() const
return bunch crossing
Definition: L1MuBMTrackSegPhi.h:109
L1MuBMTrackSegPhi::Ho
Definition: L1MuBMTrackSegPhi.h:44
L1MuBMTrackSegPhi::phiValue
double phiValue() const
return phi-value in global coordinates [0,2pi]
Definition: L1MuBMTrackSegPhi.cc:115
L1MuBMTrackSegPhi::Null
Definition: L1MuBMTrackSegPhi.h:44
L1MuBMTrackSegPhi::m_etaFlag
bool m_etaFlag
Definition: L1MuBMTrackSegPhi.h:142
L1MuBMTrackSegPhi::operator<<
friend std::ostream & operator<<(std::ostream &, const TSQuality &)
overload output stream operator for phi track segment quality
L1MuBMTrackSegPhi::LL
Definition: L1MuBMTrackSegPhi.h:44
L1MuBMTrackSegPhi::quality
int quality() const
return quality code
Definition: L1MuBMTrackSegPhi.h:103
L1MuBMTrackSegPhi::wheel
int wheel() const
return wheel
Definition: L1MuBMTrackSegPhi.h:85
L1MuBMTrackSegLoc.h
L1MuBMTrackSegLoc::wheel
int wheel() const
return wheel
Definition: L1MuBMTrackSegLoc.h:56
L1MuBMTrackSegLoc
Definition: L1MuBMTrackSegLoc.h:41
L1MuBMTrackSegPhi::HH
Definition: L1MuBMTrackSegPhi.h:44
L1MuBMTrackSegPhi::operator=
L1MuBMTrackSegPhi & operator=(const L1MuBMTrackSegPhi &)
assignment operator
Definition: L1MuBMTrackSegPhi.cc:129
L1MuBMTrackSegPhi::TSQuality
TSQuality
quality code of BBMX phi track segments
Definition: L1MuBMTrackSegPhi.h:44
L1MuBMTrackSegPhi::setEtaFlag
void setEtaFlag(bool flag)
set eta flag
Definition: L1MuBMTrackSegPhi.h:118
L1MuBMTrackSegPhi::m_tag
bool m_tag
Definition: L1MuBMTrackSegPhi.h:140
L1MuBMTrackSegPhi::empty
bool empty() const
is it an empty phi track segment?
Definition: L1MuBMTrackSegPhi.h:115
L1MuBMTrackSegPhi::reset
void reset()
reset phi track segment
Definition: L1MuBMTrackSegPhi.cc:103
L1MuBMTrackSegPhi::m_bx
int m_bx
Definition: L1MuBMTrackSegPhi.h:141
L1MuBMTrackSegPhi::where
const L1MuBMTrackSegLoc & where() const
return location of phi track segment
Definition: L1MuBMTrackSegPhi.h:94
L1MuBMTrackSegPhi::L1MuBMTrackSegPhi
L1MuBMTrackSegPhi()
default constructor
Definition: L1MuBMTrackSegPhi.cc:44
L1MuBMTrackSegPhi::Lo
Definition: L1MuBMTrackSegPhi.h:44
L1MuBMTrackSegPhi::m_quality
TSQuality m_quality
Definition: L1MuBMTrackSegPhi.h:139
L1MuBMTrackSegPhi::phibValue
double phibValue() const
return phib-value in global coordinates [0,2pi]
Definition: L1MuBMTrackSegPhi.cc:124
L1MuBMTrackSegPhi::phib
int phib() const
return phib
Definition: L1MuBMTrackSegPhi.h:100
L1MuBMTrackSegLoc::sector
int sector() const
return sector (30 deg)
Definition: L1MuBMTrackSegLoc.h:59
L1MuBMTrackSegPhi::operator==
bool operator==(const L1MuBMTrackSegPhi &) const
equal operator
Definition: L1MuBMTrackSegPhi.cc:145
L1MuBMTrackSegPhi::Hi
Definition: L1MuBMTrackSegPhi.h:44
L1MuBMTrackSegPhi::sector
int sector() const
return sector
Definition: L1MuBMTrackSegPhi.h:88
L1MuBMTrackSegPhi::etaFlag
bool etaFlag() const
return eta flag
Definition: L1MuBMTrackSegPhi.h:112
L1MuBMTrackSegPhi::phi
int phi() const
return phi
Definition: L1MuBMTrackSegPhi.h:97
L1MuBMTrackSegPhi::tag
int tag() const
return tag (second TS tag)
Definition: L1MuBMTrackSegPhi.h:106
L1MuBMTrackSegPhiCollection
std::vector< L1MuBMTrackSegPhi > L1MuBMTrackSegPhiCollection
Definition: L1MuBMTrackSegPhi.h:37
L1MuBMTrackSegPhi::m_phib
int m_phib
Definition: L1MuBMTrackSegPhi.h:138
RemoveAddSevLevel.flag
flag
Definition: RemoveAddSevLevel.py:117