CMS 3D CMS Logo

ReadoutError.h
Go to the documentation of this file.
1 #ifndef DataFormats_RPCDigi_ReadoutError_H
2 #define DataFormats_RPCDigi_ReadoutError_H
3 
5 #include <string>
6 
7 namespace rpcrawtodigi {
8  class ReadoutError {
9  public:
11  NoProblem = 0,
16  InvalidLB = 5,
20  EOD = 9
21  };
22 
23  explicit ReadoutError(unsigned int rawCode = 0) : theError(rawCode) {}
24 
26 
27  ReadoutErrorType type() const;
29 
30  static std::string name(const ReadoutErrorType& code);
31 
32  std::string name() const { return name(type()); }
33 
34  unsigned int rawCode() const { return theError; }
35 
36  private:
37  unsigned int theError;
38  };
39 
40 } // namespace rpcrawtodigi
41 #endif
LinkBoardElectronicIndex where() const
Definition: ReadoutError.cc:19
ReadoutError(unsigned int rawCode=0)
Definition: ReadoutError.h:23
std::string name() const
Definition: ReadoutError.h:32
ReadoutErrorType type() const
Definition: ReadoutError.cc:14
unsigned int rawCode() const
Definition: ReadoutError.h:34