CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Static Public Attributes | Private Member Functions | Private Attributes | Static Private Attributes | Friends
EcalChannelStatusCode Class Reference

#include <EcalChannelStatusCode.h>

Public Types

enum  Bits {
  kHV =0, kLV, kDAQ, kTP,
  kTrigger, kTemperature, kNextToDead
}
 
enum  Code {
  kOk =0, kDAC, kNoLaser, kNoisy,
  kNNoisy, kNNNoisy, kNNNNoisy, kNNNNNoisy,
  kFixedG6, kFixedG1, kFixedG0, kNonRespondingIsolated,
  kDeadVFE, kDeadFE, kNoDataNoTP
}
 

Public Member Functions

bool checkBit (Bits bit)
 Check status of desired bit. More...
 
 EcalChannelStatusCode ()
 
 EcalChannelStatusCode (const uint16_t &encodedStatus)
 
uint16_t getEncodedStatusCode () const
 Return the encoded raw status. More...
 
Code getStatusCode () const
 return decoded status More...
 
void print (std::ostream &s) const
 

Static Public Attributes

static const int chStatusMask = 0x1F
 

Private Member Functions

template<class Archive >
void serialize (Archive &ar, const unsigned int version)
 

Private Attributes

uint16_t status_
 

Static Private Attributes

static const int kBitsOffset = 5
 

Friends

class boost::serialization::access
 
template<typename CondSerializationT , typename Enabled >
struct cond::serialization::access
 

Detailed Description

Author: Paolo Meridiani Created: 14 Nov 2006

Definition at line 19 of file EcalChannelStatusCode.h.

Member Enumeration Documentation

Enumerator
kOk 
kDAC 
kNoLaser 
kNoisy 
kNNoisy 
kNNNoisy 
kNNNNoisy 
kNNNNNoisy 
kFixedG6 
kFixedG1 
kFixedG0 
kNonRespondingIsolated 
kDeadVFE 
kDeadFE 
kNoDataNoTP 

Definition at line 24 of file EcalChannelStatusCode.h.

Constructor & Destructor Documentation

EcalChannelStatusCode::EcalChannelStatusCode ( )
inline

Definition at line 54 of file EcalChannelStatusCode.h.

EcalChannelStatusCode::EcalChannelStatusCode ( const uint16_t &  encodedStatus)
inline

Definition at line 55 of file EcalChannelStatusCode.h.

55 : status_(encodedStatus) {};

Member Function Documentation

bool EcalChannelStatusCode::checkBit ( Bits  bit)
inline

Check status of desired bit.

Definition at line 67 of file EcalChannelStatusCode.h.

References kBitsOffset, and status_.

67 {return status_& (0x1<<(bit+kBitsOffset));}
static const int kBitsOffset
uint16_t EcalChannelStatusCode::getEncodedStatusCode ( ) const
inline

Return the encoded raw status.

Definition at line 64 of file EcalChannelStatusCode.h.

References status_.

64 { return status_; }
Code EcalChannelStatusCode::getStatusCode ( ) const
inline
void EcalChannelStatusCode::print ( std::ostream &  s) const
inline

Definition at line 58 of file EcalChannelStatusCode.h.

References status_.

58 { s << "status is: " << status_; }
template<class Archive >
void EcalChannelStatusCode::serialize ( Archive &  ar,
const unsigned int  version 
)
private

Friends And Related Function Documentation

friend class boost::serialization::access
friend

Definition at line 100 of file EcalChannelStatusCode.h.

template<typename CondSerializationT , typename Enabled >
friend struct cond::serialization::access
friend

Definition at line 100 of file EcalChannelStatusCode.h.

Member Data Documentation

const int EcalChannelStatusCode::chStatusMask = 0x1F
static

Definition at line 69 of file EcalChannelStatusCode.h.

Referenced by getStatusCode().

const int EcalChannelStatusCode::kBitsOffset = 5
staticprivate

Definition at line 73 of file EcalChannelStatusCode.h.

Referenced by checkBit().

uint16_t EcalChannelStatusCode::status_
private

Definition at line 98 of file EcalChannelStatusCode.h.

Referenced by checkBit(), getEncodedStatusCode(), getStatusCode(), and print().