CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
SiPixelRawDataError.h
Go to the documentation of this file.
1 #ifndef DataFormats_SiPixelRawDataError_h
2 #define DataFormats_SiPixelRawDataError_h
3 
4 //---------------------------------------------------------------------------
12 //---------------------------------------------------------------------------
13 
14 #include <string>
15 #include <stdint.h>
16 
18  public:
19 
23  SiPixelRawDataError(uint32_t errorWord32, const int errorType, int fedId);
25  SiPixelRawDataError(uint64_t errorWord64, const int errorType, int fedId);
28 
29  void setWord32(uint32_t errorWord32); // function to allow user to input the error word (if 32-bit) after instantiation
30  void setWord64(uint64_t errorWord64); // function to allow user to input the error word (if 64-bit) after instantiation
31  void setType(int errorType); // function to allow user to input the error type after instantiation
32  void setFedId(int fedId); // function to allow user to input the fedID after instantiation
33  void setMessage(); // function to create an error message based on errorType
34 
35  inline uint32_t getWord32() const {return errorWord32_;} // the 32-bit word that contains the error information
36  inline uint64_t getWord64() const {return errorWord64_;} // the 64-bit word that contains the error information
37  inline int getType() const {return errorType_;} // the number associated with the error type (26-31 for ROC number errors, 32-33 for calibration errors)
38  inline int getFedId() const {return fedId_;} // the fedId where the error occured
39  inline std::string getMessage() const {return errorMessage_;} // the error message to be displayed with the error
40 
41  private:
42 
43  uint32_t errorWord32_;
46  int fedId_;
47  std::string errorMessage_;
48 
49 };
50 
51 // Comparison operators
52 inline bool operator<( const SiPixelRawDataError& one, const SiPixelRawDataError& other) {
53  return one.getFedId() < other.getFedId();
54 }
55 
56 #endif
void setType(int errorType)
void setFedId(int fedId)
~SiPixelRawDataError()
Destructor.
void setWord32(uint32_t errorWord32)
bool operator<(const FedChannelConnection &, const FedChannelConnection &)
void setWord64(uint64_t errorWord64)
std::string getMessage() const
SiPixelRawDataError()
Default constructor.
unsigned long long uint64_t
Definition: Time.h:15
uint64_t getWord64() const
uint32_t getWord32() const
Pixel error – collection of errors and error information.