CMS 3D CMS Logo

CSCVTMBHeaderFormat.h
Go to the documentation of this file.
1 #ifndef CSCVTMBHeaderFormat_h
2 #define CSCVTMBHeaderFormat_h
3 
8 #include <vector>
9 #include <iosfwd>
10 #include <strings.h>
11 class CSCDMBHeader;
12 
14 public:
15  virtual ~CSCVTMBHeaderFormat() {}
16 
17  virtual void setEventInformation(const CSCDMBHeader&) = 0;
18  virtual uint16_t BXNCount() const = 0;
19  virtual uint16_t ALCTMatchTime() const = 0;
20  virtual uint16_t CLCTOnly() const = 0;
21  virtual uint16_t ALCTOnly() const = 0;
22  virtual uint16_t TMBMatch() const = 0;
23  virtual uint16_t Bxn0Diff() const = 0;
24  virtual uint16_t Bxn1Diff() const = 0;
25  virtual uint16_t L1ANumber() const = 0;
26  virtual uint16_t syncError() const = 0;
27  virtual uint16_t syncErrorCLCT() const = 0;
28  virtual uint16_t syncErrorMPC0() const = 0;
29  virtual uint16_t syncErrorMPC1() const = 0;
30  uint16_t sizeInBytes() const { return sizeInWords() * 2; }
31  virtual uint16_t NTBins() const = 0;
32  virtual uint16_t NCFEBs() const = 0;
33  virtual void setNCFEBs(uint16_t ncfebs) = 0;
34  virtual uint16_t firmwareRevision() const = 0;
36  virtual std::vector<CSCCLCTDigi> CLCTDigis(uint32_t idlayer) = 0;
38  virtual std::vector<CSCCorrelatedLCTDigi> CorrelatedLCTDigis(uint32_t idlayer) const = 0;
39 
42  virtual unsigned short int sizeInWords() const = 0;
43 
44  virtual unsigned short int NHeaderFrames() const = 0;
45  virtual unsigned short* data() = 0;
46  virtual bool check() const = 0;
47 
49  //void setChamberId(const CSCDetId & detId) {theChamberId = detId;}
50 
52  virtual void addCLCT0(const CSCCLCTDigi& digi) = 0;
53  virtual void addCLCT1(const CSCCLCTDigi& digi) = 0;
54  virtual void addALCT0(const CSCALCTDigi& digi) = 0;
55  virtual void addALCT1(const CSCALCTDigi& digi) = 0;
56  virtual void addCorrelatedLCT0(const CSCCorrelatedLCTDigi& digi) = 0;
57  virtual void addCorrelatedLCT1(const CSCCorrelatedLCTDigi& digi) = 0;
58 
59  virtual void print(std::ostream& os) const = 0;
60 
61 protected:
62  void swapCLCTs(CSCCLCTDigi& digi1, CSCCLCTDigi& digi2);
63 };
64 
65 #endif
CSCVTMBHeaderFormat::syncError
virtual uint16_t syncError() const =0
CSCVTMBHeaderFormat::~CSCVTMBHeaderFormat
virtual ~CSCVTMBHeaderFormat()
Definition: CSCVTMBHeaderFormat.h:15
CSCVTMBHeaderFormat::TMBMatch
virtual uint16_t TMBMatch() const =0
CSCVTMBHeaderFormat::syncErrorMPC0
virtual uint16_t syncErrorMPC0() const =0
CSCVTMBHeaderFormat::NHeaderFrames
virtual unsigned short int NHeaderFrames() const =0
CSCCorrelatedLCTDigi.h
CSCVTMBHeaderFormat::NCFEBs
virtual uint16_t NCFEBs() const =0
CSCVTMBHeaderFormat::addALCT1
virtual void addALCT1(const CSCALCTDigi &digi)=0
CSCVTMBHeaderFormat::addCLCT0
virtual void addCLCT0(const CSCCLCTDigi &digi)=0
Needed before data packing.
CSCCLCTDigi
Definition: CSCCLCTDigi.h:17
CSCDetId.h
CSCVTMBHeaderFormat::CLCTOnly
virtual uint16_t CLCTOnly() const =0
CSCVTMBHeaderFormat::addCLCT1
virtual void addCLCT1(const CSCCLCTDigi &digi)=0
CSCALCTDigi.h
CSCVTMBHeaderFormat::Bxn1Diff
virtual uint16_t Bxn1Diff() const =0
CSCVTMBHeaderFormat::BXNCount
virtual uint16_t BXNCount() const =0
CSCVTMBHeaderFormat::CorrelatedLCTDigis
virtual std::vector< CSCCorrelatedLCTDigi > CorrelatedLCTDigis(uint32_t idlayer) const =0
returns CorrelatedLCT digis
CSCVTMBHeaderFormat::Bxn0Diff
virtual uint16_t Bxn0Diff() const =0
CSCVTMBHeaderFormat::L1ANumber
virtual uint16_t L1ANumber() const =0
CSCVTMBHeaderFormat::swapCLCTs
void swapCLCTs(CSCCLCTDigi &digi1, CSCCLCTDigi &digi2)
CSCVTMBHeaderFormat::data
virtual unsigned short * data()=0
CSCVTMBHeaderFormat::NTBins
virtual uint16_t NTBins() const =0
CSCVTMBHeaderFormat::print
virtual void print(std::ostream &os) const =0
CSCVTMBHeaderFormat::ALCTOnly
virtual uint16_t ALCTOnly() const =0
CSCVTMBHeaderFormat::setEventInformation
virtual void setEventInformation(const CSCDMBHeader &)=0
CSCDMBHeader
Definition: CSCDMBHeader.h:15
CSCVTMBHeaderFormat::ALCTMatchTime
virtual uint16_t ALCTMatchTime() const =0
CSCVTMBHeaderFormat::sizeInWords
virtual unsigned short int sizeInWords() const =0
CSCVTMBHeaderFormat::addCorrelatedLCT0
virtual void addCorrelatedLCT0(const CSCCorrelatedLCTDigi &digi)=0
CSCALCTDigi
Definition: CSCALCTDigi.h:16
CSCVTMBHeaderFormat::firmwareRevision
virtual uint16_t firmwareRevision() const =0
CSCVTMBHeaderFormat::addCorrelatedLCT1
virtual void addCorrelatedLCT1(const CSCCorrelatedLCTDigi &digi)=0
CSCVTMBHeaderFormat::addALCT0
virtual void addALCT0(const CSCALCTDigi &digi)=0
CSCCLCTDigi.h
CSCVTMBHeaderFormat
Definition: CSCVTMBHeaderFormat.h:13
CSCVTMBHeaderFormat::sizeInBytes
uint16_t sizeInBytes() const
Definition: CSCVTMBHeaderFormat.h:30
CSCVTMBHeaderFormat::CLCTDigis
virtual std::vector< CSCCLCTDigi > CLCTDigis(uint32_t idlayer)=0
returns CLCT digis
CSCVTMBHeaderFormat::check
virtual bool check() const =0
CSCVTMBHeaderFormat::syncErrorMPC1
virtual uint16_t syncErrorMPC1() const =0
CSCVTMBHeaderFormat::syncErrorCLCT
virtual uint16_t syncErrorCLCT() const =0
CSCVTMBHeaderFormat::setNCFEBs
virtual void setNCFEBs(uint16_t ncfebs)=0
CSCCorrelatedLCTDigi
Definition: CSCCorrelatedLCTDigi.h:19