CMS 3D CMS Logo

CSCShowerDigi.h
Go to the documentation of this file.
1 #ifndef DataFormats_CSCDigi_CSCShowerDigi_h
2 #define DataFormats_CSCDigi_CSCShowerDigi_h
3 
4 #include <cstdint>
5 #include <iosfwd>
6 #include <limits>
7 #include <vector>
8 
9 class CSCShowerDigi {
10 public:
11  // Run-3 definitions as provided in DN-20-033
12  enum Run3Shower { kInvalid = 0, kLoose = 1, kNominal = 2, kTight = 3 };
13 
15  CSCShowerDigi(const uint16_t inTimeBits, const uint16_t outTimeBits, const uint16_t cscID);
17  CSCShowerDigi();
18 
20  void clear();
21 
23  bool isValid() const;
24 
25  bool isLooseInTime() const;
26  bool isNominalInTime() const;
27  bool isTightInTime() const;
28  bool isLooseOutOfTime() const;
29  bool isNominalOutOfTime() const;
30  bool isTightOutOfTime() const;
31 
32  uint16_t bitsInTime() const { return bitsInTime_; }
33  uint16_t bitsOutOfTime() const { return bitsOutOfTime_; }
34 
35  uint16_t getCSCID() const { return cscID_; }
36 
38  void setCSCID(const uint16_t c) { cscID_ = c; }
39 
40 private:
41  uint16_t bitsInTime_;
42  uint16_t bitsOutOfTime_;
43  // 4-bit CSC chamber identifier
44  uint16_t cscID_;
45 };
46 
47 std::ostream& operator<<(std::ostream& o, const CSCShowerDigi& digi);
48 #endif
bool isLooseOutOfTime() const
bool isValid() const
data
uint16_t bitsOutOfTime_
Definition: CSCShowerDigi.h:42
uint16_t bitsOutOfTime() const
Definition: CSCShowerDigi.h:33
void setCSCID(const uint16_t c)
set cscID
Definition: CSCShowerDigi.h:38
bool isLooseInTime() const
std::ostream & operator<<(std::ostream &o, const CSCShowerDigi &digi)
bool isTightInTime() const
bool isNominalInTime() const
bool isTightOutOfTime() const
uint16_t cscID_
Definition: CSCShowerDigi.h:44
uint16_t getCSCID() const
Definition: CSCShowerDigi.h:35
uint16_t bitsInTime() const
Definition: CSCShowerDigi.h:32
bool isNominalOutOfTime() const
uint16_t bitsInTime_
Definition: CSCShowerDigi.h:41
void clear()
clear this Shower
CSCShowerDigi()
default