LArSoft  v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
AuxDetDigit.h
Go to the documentation of this file.
1 //
3 // Definition of basic digits for auxiliary detectors
4 //
5 // brebel@fnal.gov
6 //
8 
9 #ifndef RAWDATA_AUXDETDIGIT_H
10 #define RAWDATA_AUXDETDIGIT_H
11 
12 #include <cstdint>
13 #include <iosfwd>
14 #include <string>
15 #include <vector>
16 
18 namespace raw {
19 
20  class AuxDetDigit {
21 
22  public:
23  AuxDetDigit(); // Default constructor
24 
25  private:
26  std::vector<short> fADC;
27  unsigned short fChannel;
28  std::string fAuxDetName;
29  unsigned long long fTimeStamp;
30 
33  static_assert(sizeof(unsigned long long) == 8, "unsigned long long is not 8 bytes");
34 
35  public:
36  AuxDetDigit(unsigned short channel,
37  std::vector<short> adclist,
38  std::string name = "UknownAuxDet",
39  unsigned long long timeStamp = UINT64_MAX);
40 
41  // Get Methods
42  size_t NADC() const;
43  short ADC(size_t i) const;
44  unsigned short Channel() const;
45  std::string const& AuxDetName() const;
46  unsigned long long TimeStamp() const;
47  };
48 }
49 
50 inline size_t raw::AuxDetDigit::NADC() const
51 {
52  return fADC.size();
53 }
54 inline unsigned short raw::AuxDetDigit::Channel() const
55 {
56  return fChannel;
57 }
58 inline std::string const& raw::AuxDetDigit::AuxDetName() const
59 {
60  return fAuxDetName;
61 }
62 inline unsigned long long raw::AuxDetDigit::TimeStamp() const
63 {
64  return fTimeStamp;
65 }
66 
67 #endif // RAWDATA_AUXDETDIGIT_H
68 
unsigned short Channel() const
Definition: AuxDetDigit.h:54
unsigned long long TimeStamp() const
Definition: AuxDetDigit.h:62
unsigned short fChannel
channel in the readout
Definition: AuxDetDigit.h:27
size_t NADC() const
Definition: AuxDetDigit.h:50
Raw data description.
Definition: RawTypes.h:6
std::string const & AuxDetName() const
Definition: AuxDetDigit.h:58
unsigned long long fTimeStamp
Definition: AuxDetDigit.h:29
std::vector< short > fADC
vector of adc counts
Definition: AuxDetDigit.h:26
std::string fAuxDetName
name of the detector
Definition: AuxDetDigit.h:28
short ADC(size_t i) const
Definition: AuxDetDigit.cxx:29