CMS 3D CMS Logo

L1MonitorDigi.cc
Go to the documentation of this file.
2 #include <iomanip>
3 
4 bool L1MonitorDigi::empty() const {
5  if (m_sid == m_null || m_cid == m_null || m_value == m_null)
6  return true;
7  return false;
8 }
9 
11  m_null = 999;
12  m_sid = m_null;
13  m_cid = m_null;
14  for (int i = 0; i < 3; i++)
15  m_location[i] = m_null;
16  m_data = 0;
17  m_value = m_null;
18  return m_null;
19 }
20 
22 
24  unsigned sid, unsigned cid, unsigned x1, unsigned x2, unsigned x3, unsigned value, unsigned data) {
25  reset();
26  m_sid = sid;
27  m_cid = cid;
28  m_location[0] = x1;
29  m_location[1] = x2;
30  m_location[2] = x3;
31  m_value = value;
32  m_data = data;
33 }
34 
36 
37 std::ostream& operator<<(std::ostream& s, const L1MonitorDigi& mon) {
38  s << "L1Mon "
39  << " system: " << std::setw(2) << mon.sid() << " (cid." << std::setw(2) << mon.cid() << ")" << std::hex
40  << std::setfill('0') << " location: "
41  << "(" << std::setw(5) << std::setprecision(2) << mon.x1() << "," << std::setw(5) << std::setprecision(2)
42  << mon.x2() << "," << std::setw(5) << std::setprecision(2) << mon.x3() << ")"
43  << " value: " << std::setw(5) << std::setprecision(2) << mon.value() << " word: " << std::setw(8) << mon.raw()
44  << std::dec << std::setfill(' ');
45  return s;
46 }
unsigned sid() const
Definition: L1MonitorDigi.h:30
unsigned m_location[3]
Definition: L1MonitorDigi.h:44
unsigned m_null
Definition: L1MonitorDigi.h:47
std::ostream & operator<<(std::ostream &s, const L1MonitorDigi &mon)
unsigned m_sid
Definition: L1MonitorDigi.h:42
unsigned value() const
Definition: L1MonitorDigi.h:36
bool empty() const
Definition: L1MonitorDigi.cc:4
unsigned m_value
Definition: L1MonitorDigi.h:45
unsigned m_data
Definition: L1MonitorDigi.h:46
unsigned x2() const
Definition: L1MonitorDigi.h:33
unsigned x1() const
Definition: L1MonitorDigi.h:32
unsigned m_cid
Definition: L1MonitorDigi.h:43
unsigned cid() const
Definition: L1MonitorDigi.h:31
unsigned x3() const
Definition: L1MonitorDigi.h:34
Definition: value.py:1
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:79
unsigned reset()