LDMX Software
|
Represents a collection of the ECal digi hits. More...
#include <EcalDigiCollection.h>
Public Member Functions | |
EcalDigiCollection () | |
Class constructor. | |
virtual | ~EcalDigiCollection () |
Class destructor. | |
void | Clear () |
Clear the data in the object. | |
void | Print () const |
Print out the object. | |
unsigned int | getNumSamplesPerDigi () const |
Get number of samples per digi. | |
void | setNumSamplesPerDigi (unsigned int n) |
Set number of samples for each digi. | |
unsigned int | getSampleOfInterestIndex () const |
Get index of sample of interest. | |
void | setSampleOfInterestIndex (unsigned int n) |
Set index of sample of interest. | |
std::vector< EcalDigiSample > | getDigi (unsigned int digiIndex) const |
Get samples for the input digi index. | |
unsigned int | getNumDigis () const |
Get total number of digis. | |
void | addDigi (std::vector< EcalDigiSample > newSamples) |
Translate and add samples to collection. | |
Private Member Functions | |
ClassDef (EcalDigiCollection, 1) | |
The ROOT class definition. | |
Private Attributes | |
std::vector< int > | channelIDs_ |
list of channel IDs that we have digis for | |
std::vector< int32_t > | samples_ |
list of samples that we have been given | |
unsigned int | numSamplesPerDigi_ {1} |
number of samples for each digi | |
unsigned int | sampleOfInterest_ {0} |
index for the sample of interest in the samples list | |
Static Private Attributes | |
static const int | ONE_BIT_MASK = 1 |
Mask for lowest order bit in an int. | |
static const int | TEN_BIT_MASK = (1 << 10) - 1 |
Mask for lowest order ten bits in an int. | |
static const int | FIRSTFLAG_POS = 31 |
Bit position of first flag. | |
static const int | SECONFLAG_POS = 30 |
Bit position of second flag. | |
static const int | FIRSTMEAS_POS = 20 |
Bit position of first measurement. | |
static const int | SECONMEAS_POS = 10 |
Bit position of second measurement. | |
Represents a collection of the ECal digi hits.
Each digi corresponds to a one channel ID and numSamplesPerDigi_ samples.
Definition at line 58 of file EcalDigiCollection.h.
|
inline |
|
inlinevirtual |
void ldmx::EcalDigiCollection::Clear | ( | ) |
Clear the data in the object.
Clears the vectors of channel IDs and samples, but does not change the number of samples per digi setting.
|
inline |
Get total number of digis.
Definition at line 120 of file EcalDigiCollection.h.
References channelIDs_.
|
inline |
Get number of samples per digi.
Definition at line 89 of file EcalDigiCollection.h.
References numSamplesPerDigi_.
|
inline |
Get index of sample of interest.
Definition at line 102 of file EcalDigiCollection.h.
References sampleOfInterest_.
void ldmx::EcalDigiCollection::Print | ( | ) | const |
Print out the object.
Prints out the lengths of the stored vectors and the number of samples per digi setting.
|
inline |
Set number of samples for each digi.
Definition at line 94 of file EcalDigiCollection.h.
References numSamplesPerDigi_.
|
inline |
Set index of sample of interest.
Definition at line 107 of file EcalDigiCollection.h.
References sampleOfInterest_.
|
private |
list of channel IDs that we have digis for
Definition at line 148 of file EcalDigiCollection.h.
Referenced by getNumDigis().
|
staticprivate |
Bit position of first flag.
Definition at line 135 of file EcalDigiCollection.h.
|
staticprivate |
Bit position of first measurement.
Definition at line 141 of file EcalDigiCollection.h.
|
private |
number of samples for each digi
Definition at line 154 of file EcalDigiCollection.h.
Referenced by getNumSamplesPerDigi(), and setNumSamplesPerDigi().
|
staticprivate |
Mask for lowest order bit in an int.
Definition at line 129 of file EcalDigiCollection.h.
|
private |
index for the sample of interest in the samples list
Definition at line 157 of file EcalDigiCollection.h.
Referenced by getSampleOfInterestIndex(), and setSampleOfInterestIndex().
|
private |
list of samples that we have been given
Definition at line 151 of file EcalDigiCollection.h.
|
staticprivate |
Bit position of second flag.
Definition at line 138 of file EcalDigiCollection.h.
|
staticprivate |
Bit position of second measurement.
Definition at line 144 of file EcalDigiCollection.h.
|
staticprivate |
Mask for lowest order ten bits in an int.
Definition at line 132 of file EcalDigiCollection.h.