CMS 3D CMS Logo

SiPixelCalibDigiError.h
Go to the documentation of this file.
1 //---------------------------------------------------
2 
3 // Author : Freya.Blekman@NOSPAM.cern.ch
4 // Name : SiPixelCalibDigiError
5 
6 //---------------------------------------------------
7 
8 #ifndef DataFormats_SiPixelCalibDigi_SiPixelCalibDigiError_H
9 #define DataFormats_SiPixelCalibDigi_SiPixelCalibDigiError_H
10 
11 #include <iostream>
12 #include <utility>
13 #include <string>
14 #include <cstdint>
15 
17 private:
18  uint16_t fRow; // row number
19  uint16_t fCol; // column number
20  uint8_t fErrorType; // error type in case we want to label errors
21 
22 public:
24 
25  SiPixelCalibDigiError(uint16_t row, uint16_t col) : fRow(row), fCol(col), fErrorType(0) { ; }
26  SiPixelCalibDigiError(uint16_t row, uint16_t col, uint16_t error) : fRow(row), fCol(col), fErrorType(error) { ; }
27 
28  virtual ~SiPixelCalibDigiError() { ; }
29 
30  //- Accessible methods
31 
32  //-- Setter/Getter
33 
34  uint16_t getRow() const { return fRow; }
35  void setRow(const uint16_t& in) { fRow = in; }
36 
37  uint16_t getCol() const { return fCol; }
38  void setCol(const uint16_t& in) { fCol = in; }
39 
40  uint16_t getErrorType() const { return fErrorType; }
41  void setErrorType(const uint16_t& in) { fErrorType = in; }
42  std::string printError() const;
43 };
45  if (one.getCol() != other.getCol())
46  return one.getCol() < other.getCol();
47 
48  return one.getRow() < other.getRow();
49 }
50 inline std::ostream& operator<<(std::ostream& output, const SiPixelCalibDigiError& err) {
51  std::string errorstr = err.printError();
52  return output << "pixel SiCalibDigi error in row " << err.getRow() << ", column " << err.getCol() << " of type "
53  << err.getErrorType() << " (" << errorstr << ")";
54 }
55 #endif
SiPixelCalibDigiError::SiPixelCalibDigiError
SiPixelCalibDigiError()
Definition: SiPixelCalibDigiError.h:23
SiPixelCalibDigiError::fCol
uint16_t fCol
Definition: SiPixelCalibDigiError.h:19
SiPixelPI::one
Definition: SiPixelPayloadInspectorHelper.h:39
operator<
bool operator<(const SiPixelCalibDigiError &one, const SiPixelCalibDigiError other)
Definition: SiPixelCalibDigiError.h:44
SiPixelCalibDigiError::SiPixelCalibDigiError
SiPixelCalibDigiError(uint16_t row, uint16_t col)
Definition: SiPixelCalibDigiError.h:25
convertSQLitetoXML_cfg.output
output
Definition: convertSQLitetoXML_cfg.py:72
SiPixelCalibDigiError::printError
std::string printError() const
Definition: SiPixelCalibDigiError.cc:3
hcal_dqm_sourceclient-live_cfg.errorstr
errorstr
Definition: hcal_dqm_sourceclient-live_cfg.py:20
cuy.col
col
Definition: cuy.py:1010
relativeConstraints.error
error
Definition: relativeConstraints.py:53
SiPixelCalibDigiError::getRow
uint16_t getRow() const
Definition: SiPixelCalibDigiError.h:34
SiPixelCalibDigiError::setCol
void setCol(const uint16_t &in)
Definition: SiPixelCalibDigiError.h:38
SiPixelCalibDigiError::setRow
void setRow(const uint16_t &in)
Definition: SiPixelCalibDigiError.h:35
trackingPlots.other
other
Definition: trackingPlots.py:1460
SiPixelCalibDigiError::setErrorType
void setErrorType(const uint16_t &in)
Definition: SiPixelCalibDigiError.h:41
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
SiPixelCalibDigiError
Definition: SiPixelCalibDigiError.h:16
recoMuon::in
Definition: RecoMuonEnumerators.h:6
submitPVResolutionJobs.err
err
Definition: submitPVResolutionJobs.py:85
SiPixelCalibDigiError::getErrorType
uint16_t getErrorType() const
Definition: SiPixelCalibDigiError.h:40
SiPixelCalibDigiError::fErrorType
uint8_t fErrorType
Definition: SiPixelCalibDigiError.h:20
SiPixelCalibDigiError::~SiPixelCalibDigiError
virtual ~SiPixelCalibDigiError()
Definition: SiPixelCalibDigiError.h:28
operator<<
std::ostream & operator<<(std::ostream &output, const SiPixelCalibDigiError &err)
Definition: SiPixelCalibDigiError.h:50
SiPixelCalibDigiError::fRow
uint16_t fRow
Definition: SiPixelCalibDigiError.h:18
SiPixelCalibDigiError::getCol
uint16_t getCol() const
Definition: SiPixelCalibDigiError.h:37
SiPixelCalibDigiError::SiPixelCalibDigiError
SiPixelCalibDigiError(uint16_t row, uint16_t col, uint16_t error)
Definition: SiPixelCalibDigiError.h:26