CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
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 
13 
15 public:
16  virtual ~CSCVTMBHeaderFormat() {}
17  void init() {
18  bzero(this, sizeInWords()*2);
19  }
20 
21  virtual void setEventInformation(const CSCDMBHeader &) = 0;
22  virtual uint16_t BXNCount() const = 0;
23  virtual uint16_t ALCTMatchTime() const = 0;
24  virtual uint16_t CLCTOnly() const = 0;
25  virtual uint16_t ALCTOnly() const = 0;
26  virtual uint16_t TMBMatch() const = 0;
27  virtual uint16_t Bxn0Diff() const = 0;
28  virtual uint16_t Bxn1Diff() const = 0;
29  virtual uint16_t L1ANumber() const = 0;
30  virtual uint16_t syncError() const = 0;
31  virtual uint16_t syncErrorCLCT() const = 0;
32  virtual uint16_t syncErrorMPC0() const = 0;
33  virtual uint16_t syncErrorMPC1() const = 0;
34  uint16_t sizeInBytes() const {
35  return sizeInWords()*2;
36  }
37  virtual uint16_t NTBins() const = 0;
38  virtual uint16_t NCFEBs() const = 0;
39  virtual void setNCFEBs(uint16_t ncfebs) = 0;
40  virtual uint16_t firmwareRevision() const = 0;
42  virtual std::vector<CSCCLCTDigi> CLCTDigis(uint32_t idlayer) = 0;
44  virtual std::vector<CSCCorrelatedLCTDigi> CorrelatedLCTDigis(uint32_t idlayer) const = 0;
45 
46 
49  virtual unsigned short int sizeInWords() const = 0;
50 
51  virtual unsigned short int NHeaderFrames() const = 0;
52  virtual unsigned short * data() = 0;
53  virtual bool check() const = 0;
54 
56  //void setChamberId(const CSCDetId & detId) {theChamberId = detId;}
57 
59  virtual void addCLCT0(const CSCCLCTDigi & digi) = 0;
60  virtual void addCLCT1(const CSCCLCTDigi & digi) = 0;
61  virtual void addALCT0(const CSCALCTDigi & digi) = 0;
62  virtual void addALCT1(const CSCALCTDigi & digi) = 0;
63  virtual void addCorrelatedLCT0(const CSCCorrelatedLCTDigi & digi) = 0;
64  virtual void addCorrelatedLCT1(const CSCCorrelatedLCTDigi & digi) = 0;
65 
66 
67  virtual void print(std::ostream & os) const = 0;
68 protected:
69 
70  void swapCLCTs(CSCCLCTDigi& digi1, CSCCLCTDigi& digi2);
71 };
72 
73 #endif
74 
virtual void addCorrelatedLCT0(const CSCCorrelatedLCTDigi &digi)=0
virtual unsigned short * data()=0
virtual uint16_t NCFEBs() const =0
virtual uint16_t CLCTOnly() const =0
virtual uint16_t TMBMatch() const =0
virtual void addCorrelatedLCT1(const CSCCorrelatedLCTDigi &digi)=0
virtual uint16_t ALCTMatchTime() const =0
virtual uint16_t syncErrorCLCT() const =0
virtual void addALCT1(const CSCALCTDigi &digi)=0
virtual uint16_t firmwareRevision() const =0
virtual void print(std::ostream &os) const =0
virtual void addCLCT0(const CSCCLCTDigi &digi)=0
Needed before data packing.
uint16_t sizeInBytes() const
virtual unsigned short int NHeaderFrames() const =0
virtual void addALCT0(const CSCALCTDigi &digi)=0
virtual std::vector< CSCCorrelatedLCTDigi > CorrelatedLCTDigis(uint32_t idlayer) const =0
returns CorrelatedLCT digis
virtual uint16_t Bxn0Diff() const =0
virtual void setEventInformation(const CSCDMBHeader &)=0
virtual uint16_t ALCTOnly() const =0
virtual uint16_t Bxn1Diff() const =0
virtual void addCLCT1(const CSCCLCTDigi &digi)=0
virtual void setNCFEBs(uint16_t ncfebs)=0
virtual uint16_t syncErrorMPC0() const =0
virtual std::vector< CSCCLCTDigi > CLCTDigis(uint32_t idlayer)=0
returns CLCT digis
virtual unsigned short int sizeInWords() const =0
virtual uint16_t BXNCount() const =0
virtual uint16_t syncError() const =0
void swapCLCTs(CSCCLCTDigi &digi1, CSCCLCTDigi &digi2)
virtual uint16_t NTBins() const =0
virtual uint16_t L1ANumber() const =0
virtual bool check() const =0
virtual uint16_t syncErrorMPC1() const =0