ATLAS Offline Software
FineTimeErrorCode.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef TRIGT1CALOCALIBCONDITIONS_FINETIMEERRORCODE_H
6 #define TRIGT1CALOCALIBCONDITIONS_FINETIMEERRORCODE_H
7 
9 
10 #include <string>
11 
20 
21  friend std::ostream& operator<<(std::ostream& output, const FineTimeErrorCode& r);
22 
23 public:
24 
25  enum FineTimeBits {
26 
27  BadRefBit = 0, //set if reference value couldn't be retrieved
28  BadCalibBit = 1, //set if calib value couldn't be retrieved
29  RefSetByHand = 2, //set if the reference value is set by hand
30  CalibSetByHand = 3 //set if the calibration value is set by hand
31  };
32 
34  FineTimeErrorCode(unsigned int errorCode);
35  virtual ~FineTimeErrorCode() {}
36 
40 
41  bool badRefValue() const { return bitIsSet(BadRefBit); }
42  void badRefValue(bool bad) { setBit(BadRefBit,bad); }
43 
44  bool badCalib() const { return bitIsSet(BadCalibBit); }
45  void badAdc(bool bad) { setBit(BadCalibBit,bad); }
46 
47  bool isRefSetByHand() const { return bitIsSet(RefSetByHand); }
49 
50  bool isCalibSetByHand() const { return bitIsSet(CalibSetByHand); }
52 
53  std::string printStatus() const;
54 };
55 
56 #endif
57 
58 
FineTimeErrorCode::RefSetByHand
@ RefSetByHand
Definition: FineTimeErrorCode.h:29
bad
@ bad
Definition: SUSYToolsTester.cxx:100
AllowedVariables::e
e
Definition: AsgElectronSelectorTool.cxx:37
beamspotman.r
def r
Definition: beamspotman.py:676
FineTimeErrorCode
FineTimeErrorCode class for L1Calo error codes.
Definition: FineTimeErrorCode.h:19
AbstractErrorCode::setBit
void setBit(unsigned int number, bool value)
Definition: AbstractErrorCode.cxx:15
AbstractErrorCode::errorCode
unsigned int errorCode() const
Definition: AbstractErrorCode.h:21
FineTimeErrorCode::operator=
FineTimeErrorCode & operator=(const FineTimeErrorCode &e)
Definition: FineTimeErrorCode.cxx:21
FineTimeErrorCode::BadCalibBit
@ BadCalibBit
Definition: FineTimeErrorCode.h:28
FineTimeErrorCode::printStatus
std::string printStatus() const
Definition: FineTimeErrorCode.cxx:33
FineTimeErrorCode::refIsSetByHand
void refIsSetByHand(bool bad)
Definition: FineTimeErrorCode.h:48
FineTimeErrorCode::isCalibSetByHand
bool isCalibSetByHand() const
Definition: FineTimeErrorCode.h:50
FineTimeErrorCode::FineTimeBits
FineTimeBits
Definition: FineTimeErrorCode.h:25
FineTimeErrorCode::BadRefBit
@ BadRefBit
Definition: FineTimeErrorCode.h:27
FineTimeErrorCode::isRefSetByHand
bool isRefSetByHand() const
Definition: FineTimeErrorCode.h:47
FineTimeErrorCode::badCalib
bool badCalib() const
Definition: FineTimeErrorCode.h:44
FineTimeErrorCode::CalibSetByHand
@ CalibSetByHand
Definition: FineTimeErrorCode.h:30
FineTimeErrorCode::badRefValue
void badRefValue(bool bad)
Definition: FineTimeErrorCode.h:42
FineTimeErrorCode::calibIsSetByHand
void calibIsSetByHand(bool bad)
Definition: FineTimeErrorCode.h:51
AbstractErrorCode::bitIsSet
bool bitIsSet(unsigned int number) const
Definition: AbstractErrorCode.cxx:7
FineTimeErrorCode::operator<<
friend std::ostream & operator<<(std::ostream &output, const FineTimeErrorCode &r)
Definition: FineTimeErrorCode.cxx:58
FineTimeErrorCode::badAdc
void badAdc(bool bad)
Definition: FineTimeErrorCode.h:45
merge.output
output
Definition: merge.py:17
FineTimeErrorCode::FineTimeErrorCode
FineTimeErrorCode()
Definition: FineTimeErrorCode.cxx:12
FineTimeErrorCode::badRefValue
bool badRefValue() const
Definition: FineTimeErrorCode.h:41
AbstractErrorCode
AbstractErrorCode abstract base class for L1Calo error codes.
Definition: AbstractErrorCode.h:16
FineTimeErrorCode::operator|=
FineTimeErrorCode & operator|=(const FineTimeErrorCode &e)
Definition: FineTimeErrorCode.cxx:27
FineTimeErrorCode::~FineTimeErrorCode
virtual ~FineTimeErrorCode()
Definition: FineTimeErrorCode.h:35
AbstractErrorCode.h