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 
15 
16 #include <string>
17 #include <stdint.h>
18 
20  public:
21 
25  SiPixelRawDataError(cms_uint32_t errorWord32, const int errorType, int fedId);
27  SiPixelRawDataError(cms_uint64_t errorWord64, const int errorType, int fedId);
30 
31  void setWord32(cms_uint32_t errorWord32); // function to allow user to input the error word (if 32-bit) after instantiation
32  void setWord64(cms_uint64_t errorWord64); // function to allow user to input the error word (if 64-bit) after instantiation
33  void setType(int errorType); // function to allow user to input the error type after instantiation
34  void setFedId(int fedId); // function to allow user to input the fedID after instantiation
35  void setMessage(); // function to create an error message based on errorType
36 
37  inline cms_uint32_t getWord32() const {return errorWord32_;} // the 32-bit word that contains the error information
38  inline cms_uint64_t getWord64() const {return errorWord64_;} // the 64-bit word that contains the error information
39  inline int getType() const {return errorType_;} // the number associated with the error type (26-31 for ROC number errors, 32-33 for calibration errors)
40  inline int getFedId() const {return fedId_;} // the fedId where the error occured
41  inline std::string getMessage() const {return errorMessage_;} // the error message to be displayed with the error
42 
43  private:
44 
48  int fedId_;
49  std::string errorMessage_;
50 
51 };
52 
53 // Comparison operators
54 inline bool operator<( const SiPixelRawDataError& one, const SiPixelRawDataError& other) {
55  return one.getFedId() < other.getFedId();
56 }
57 
58 #endif
void setType(int errorType)
void setWord32(cms_uint32_t errorWord32)
void setFedId(int fedId)
~SiPixelRawDataError()
Destructor.
bool operator<(const FedChannelConnection &, const FedChannelConnection &)
unsigned int cms_uint32_t
Definition: typedefs.h:15
std::string getMessage() const
SiPixelRawDataError()
Default constructor.
cms_uint32_t getWord32() const
cms_uint64_t getWord64() const
unsigned long long cms_uint64_t
Definition: typedefs.h:17
Pixel error – collection of errors and error information.
void setWord64(cms_uint64_t errorWord64)