Belle II Software  release-06-00-14
KLMChannelStatus.h
1 /**************************************************************************
2  * basf2 (Belle II Analysis Software Framework) *
3  * Author: The Belle II Collaboration *
4  * *
5  * See git log for contributors and copyright holders. *
6  * This file is licensed under LGPL-3.0, see LICENSE.md. *
7  **************************************************************************/
8 
9 #pragma once
10 
11 /* KLM headers. */
12 #include <klm/dataobjects/KLMElementNumberDefinitions.h>
13 
14 /* ROOT headers. */
15 #include <TObject.h>
16 
17 /* C++ headers. */
18 #include <cstdint>
19 #include <map>
20 
21 namespace Belle2 {
30  class KLMChannelStatus : public TObject {
31 
32  public:
33 
38 
41 
44 
47 
50 
53 
54  };
55 
60 
65 
71 
77  void setChannelStatus(KLMChannelNumber channel, enum ChannelStatus status);
78 
83  void setStatusAllChannels(enum ChannelStatus status);
84 
89  int getActiveStripsInModule(KLMChannelNumber module) const;
90 
94  bool operator==(KLMChannelStatus& status);
95 
100  unsigned int newNormalChannels(KLMChannelStatus& status);
101 
102  private:
103 
105  std::map<KLMChannelNumber, enum ChannelStatus> m_ChannelStatus;
106 
109 
110  };
111 
113 }
KLM channel status.
void setChannelStatus(KLMChannelNumber channel, enum ChannelStatus status)
Set channel status.
enum ChannelStatus getChannelStatus(KLMChannelNumber channel) const
Get channel status.
void setStatusAllChannels(enum ChannelStatus status)
Set staus for all channels.
ClassDef(Belle2::KLMChannelStatus, 1)
Class version.
int getActiveStripsInModule(KLMChannelNumber module) const
Get number of active strips in the specified KLM module.
bool operator==(KLMChannelStatus &status)
Operator ==.
std::map< KLMChannelNumber, enum ChannelStatus > m_ChannelStatus
Channel data.
ChannelStatus
Channel status.
@ c_Hot
Hot channel (large background).
@ c_Undetermined
Undetermined (used during calibration).
@ c_Normal
Normally operating channel.
@ c_Dead
Dead channel (no signal).
@ c_Unknown
Unknown status (no data).
unsigned int newNormalChannels(KLMChannelStatus &status)
Number of new channels with status c_Normal that have a different status in another channel-status da...
uint16_t KLMChannelNumber
Channel number.
Abstract base class for different kinds of events.