Belle II Software  release-08-01-10
ARICHDigit.cc
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 #include <arich/dataobjects/ARICHDigit.h>
10 
11 using namespace std;
12 using namespace Belle2;
13 
14 DigitBase::EAppendStatus ARICHDigit::addBGDigit(const DigitBase* bg)
15 {
16 
17  const auto* bgDigit = static_cast<const ARICHDigit*>(bg);
18  uint8_t bg_bitmap = bgDigit->getBitmap();
19  int i = 0;
20  while (bg_bitmap >> i) {
21  if (m_bitmap == 0xF) break;
22  m_bitmap = (m_bitmap << 1) + 1;
23  i++;
24  }
25 
26  return DigitBase::c_DontAppend;
27 
28 }
29 
ARICHDigit class for storing photon hit information.
Definition: ARICHDigit.h:27
uint8_t getBitmap() const
Get global time of hit.
Definition: ARICHDigit.h:66
A common base for subdetector Digits.
Definition: DigitBase.h:26
EAppendStatus
Enum for return state of addBGDigit function.
Definition: DigitBase.h:32
Abstract base class for different kinds of events.