CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CSCDDUStatusDigi.cc
Go to the documentation of this file.
1 
9 #include <ostream>
10 #include <cstring>
11 #include <iostream>
12 
13 CSCDDUStatusDigi::CSCDDUStatusDigi(const uint16_t * header, const uint16_t * trailer, uint16_t tts)
14 {
15  uint16_t headerSizeInBytes =24;
16  uint16_t trailerSizeInBytes =24;
17  memcpy(header_, header, headerSizeInBytes);
18  memcpy(trailer_, trailer, trailerSizeInBytes);
19  tts_=tts;
20 }
21 
22 const uint16_t CSCDDUStatusDigi::getDDUTTS() const {
23  uint16_t ttsBits = (tts_ & 0x00F0) >> 4;
24  return ttsBits;
25 }
26 
28  edm::LogVerbatim("CSCDigi") << " Header: " << std::hex << *header_ <<
29  " Trailer: " << std::hex << *trailer_ << " TTS: " << getDDUTTS() << std::dec;
30 }
31 
32 std::ostream & operator<<(std::ostream & o, const CSCDDUStatusDigi& digi) {
33  o << " ";
34  o <<"\n";
35 
36  return o;
37 }
38 
std::ostream & operator<<(std::ostream &out, const ALILine &li)
Definition: ALILine.cc:187
uint16_t trailer_[12]
void print() const
Print the content of CSCDDUStatusDigi.
CSCDDUStatusDigi()
Default constructor.
uint16_t header_[12]
const uint16_t getDDUTTS() const