BmnRoot 26.10.0-18-g4e3414f9
Software framework of the BM@N experiment
Loading...
Searching...
No Matches
BmnHgndDigi.h
Go to the documentation of this file.
1/**
2 * \file BmnHgndDigi.h
3 * \author Nikolay Karpushkin <karpushkin@inr.ru>
4 * \date 12.04.2025
5 * \brief Data class for HGND digis in the BM@N experiment.
6 */
7
8#ifndef BmnHgndDigi_H
9#define BmnHgndDigi_H 1
10
11#include "BmnNdetDigit.h" // Base class
12
13/**
14 * \class BmnHgndDigi
15 * \brief Data structure for a single HGND digit.
16 *
17 * Inherits from BmnNdetDigit and adds ToA / ToT fields.
18 */
20{
21 public:
22 /// Default constructor
23 BmnHgndDigi() = default;
24
25 /// Constructor with all parameters
26 BmnHgndDigi(uint32_t address, double time, double signal, double toa, double tot)
27 : BmnNdetDigit(address, time, signal)
28 , fToa(toa)
29 , fTot(tot)
30 {}
31
32 /// Destructor
33 virtual ~BmnHgndDigi() = default;
34
35 /// Reset digit content to default state
36 void reset() override final
37 {
39 fToa = 0.0;
40 fTot = 0.0;
41 }
42
43 /// Returns the class name
44 const char* GetClassName() override final { return "BmnHgndDigi"; }
45
46 /// Set Time-over-Threshold (in ns)
47 void SetTot(double tot) { fTot = tot; }
48
49 /// Set Time-of-Arrival (in ns)
50 void SetToa(double toa) { fToa = toa; }
51
52 /// Get Time-over-Threshold (in ns)
53 double GetTot() const { return fTot; }
54
55 /// Get Time-of-Arrival (in ns)
56 double GetToa() const { return fToa; }
57
58 private:
59 double fToa = 0.0; // Time-of-Arrival
60 double fTot = 0.0; // Time-over-Threshold
61
63};
64
65#endif // BmnHgndDigi_H
#define ClassDefOverride(name, id)
virtual void reset()
double GetToa() const
Get Time-of-Arrival (in ns).
Definition BmnHgndDigi.h:56
const char * GetClassName() override final
Returns the class name.
Definition BmnHgndDigi.h:44
void SetTot(double tot)
Set Time-over-Threshold (in ns).
Definition BmnHgndDigi.h:47
BmnHgndDigi()=default
Default constructor.
double fTot
Definition BmnHgndDigi.h:60
void SetToa(double toa)
Set Time-of-Arrival (in ns).
Definition BmnHgndDigi.h:50
virtual ~BmnHgndDigi()=default
Destructor.
double fToa
Definition BmnHgndDigi.h:59
void reset() override final
Reset digit content to default state.
Definition BmnHgndDigi.h:36
BmnHgndDigi(uint32_t address, double time, double signal, double toa, double tot)
Constructor with all parameters.
Definition BmnHgndDigi.h:26
double GetTot() const
Get Time-over-Threshold (in ns).
Definition BmnHgndDigi.h:53