Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
srcs
larevt
larevt
CalibrationDBI
IOVData
ChannelStatus.h
Go to the documentation of this file.
1
/**
2
* \file ChannelStatus.h
3
*
4
* \ingroup IOVData
5
*
6
* \brief Class def header for a class ChannelStatus
7
*
8
* @author eberly@slac.stanford.edu
9
*/
10
11
/** \addtogroup IOVData
12
13
@{*/
14
#ifndef IOVDATA_CHANNELSTATUS_H
15
#define IOVDATA_CHANNELSTATUS_H 1
16
17
#include "
ChData.h
"
18
19
namespace
lariov {
20
21
enum
chStatus
{
kDISCONNECTED
=0,
kDEAD
=1,
kLOWNOISE
=2,
kNOISY
=3,
kGOOD
=4,
kUNKNOWN
=5};
22
23
/**
24
\class ChannelStatus
25
*/
26
class
ChannelStatus
:
public
ChData
{
27
28
public
:
29
30
/// Constructor
31
ChannelStatus
(
unsigned
int
ch) :
ChData
(ch) {}
32
33
/// Default destructor
34
~ChannelStatus
() =
default
;
35
36
bool
IsDead
()
const
{
return
fStatus
==
kDEAD
?
true
:
false
; }
37
bool
IsLowNoise
()
const
{
return
fStatus
==
kLOWNOISE
?
true
:
false
; }
38
bool
IsNoisy
()
const
{
return
fStatus
==
kNOISY
?
true
:
false
; }
39
bool
IsPresent
()
const
{
return
fStatus
==
kDISCONNECTED
?
false
:
true
; }
40
bool
IsGood
()
const
{
return
fStatus
==
kGOOD
?
true
:
false
; }
41
chStatus
Status
()
const
{
return
fStatus
; }
42
43
void
SetStatus
(
chStatus
status) {
fStatus
= status; }
44
45
static
chStatus
GetStatusFromInt
(
int
status) {
46
switch
(status)
47
{
48
case
kDISCONNECTED
:
return
kDISCONNECTED
;
49
break
;
50
case
kDEAD
:
return
kDEAD
;
51
break
;
52
case
kLOWNOISE
:
return
kLOWNOISE
;
53
break
;
54
case
kNOISY
:
return
kNOISY
;
55
break
;
56
case
kGOOD
:
return
kGOOD
;
57
break
;
58
default
:
return
kUNKNOWN
;
59
};
60
61
return
kUNKNOWN
;
62
}
63
64
private
:
65
chStatus
fStatus
;
66
};
//end class
67
}
//end namespace lariov
68
69
#endif
70
/** @} */
//end doxygen group
lariov::ChannelStatus::IsNoisy
bool IsNoisy() const
Definition:
ChannelStatus.h:38
lariov::ChannelStatus::IsPresent
bool IsPresent() const
Definition:
ChannelStatus.h:39
lariov::ChannelStatus::Status
chStatus Status() const
Definition:
ChannelStatus.h:41
lariov::ChData
Definition:
ChData.h:23
lariov::ChannelStatus::IsLowNoise
bool IsLowNoise() const
Definition:
ChannelStatus.h:37
lariov::ChannelStatus::fStatus
chStatus fStatus
Definition:
ChannelStatus.h:65
lariov::kGOOD
Definition:
ChannelStatus.h:21
lariov::ChannelStatus::GetStatusFromInt
static chStatus GetStatusFromInt(int status)
Definition:
ChannelStatus.h:45
lariov::kDEAD
Definition:
ChannelStatus.h:21
lariov::ChannelStatus::IsDead
bool IsDead() const
Definition:
ChannelStatus.h:36
lariov::ChannelStatus::IsGood
bool IsGood() const
Definition:
ChannelStatus.h:40
lariov::kLOWNOISE
Definition:
ChannelStatus.h:21
lariov::ChannelStatus::ChannelStatus
ChannelStatus(unsigned int ch)
Constructor.
Definition:
ChannelStatus.h:31
lariov::kDISCONNECTED
Definition:
ChannelStatus.h:21
lariov::kUNKNOWN
Definition:
ChannelStatus.h:21
lariov::kNOISY
Definition:
ChannelStatus.h:21
lariov::ChannelStatus
Definition:
ChannelStatus.h:26
lariov::chStatus
chStatus
Definition:
ChannelStatus.h:21
ChData.h
Class def header for a class ChData.
lariov::ChannelStatus::~ChannelStatus
~ChannelStatus()=default
Default destructor.
lariov::ChannelStatus::SetStatus
void SetStatus(chStatus status)
Definition:
ChannelStatus.h:43
Generated by
1.8.5