Berkeley Nuclear Data Software
Public Member Functions | Public Attributes | List of all members
MDPP16Event Class Reference

#include <MDPP16DataStructures.h>

Public Member Functions

 MDPP16Event ()
 default construction leads to an empty container More...
 
void clear ()
 resets the internal data structures More...
 
void addQDCHits (int a_channel, const vector< MDPP16ChargeData > &a_charges, const vector< uint16_t > &a_times, const vector< MDPP16ChargeData > &a_peakCharges)
 this adder assumed that there is data in each of the vectors. More...
 
void addSCPHits (int a_channel, const vector< MDPP16ChargeData > &a_charges, const vector< uint16_t > &a_times)
 this adder assumed that there is data in each of the vectors. More...
 
void addCharges (int a_channel, const vector< MDPP16ChargeData > &a_charges)
 adds content to the charge map More...
 
void addTimes (int a_channel, const vector< uint16_t > &a_times)
 
void addPeakCharges (int a_channel, const vector< MDPP16ChargeData > &a_charges)
 adds content to the peak charge map More...
 
void addPeakCharge (int a_channel, MDPP16ChargeData a_charge)
 adds content to the peak charge map More...
 
void addCharge (int a_channel, MDPP16ChargeData a_charge)
 adds content to the charge map More...
 
void addTime (int a_channel, uint16_t a_time)
 
void setExtTimeStamp (uint16_t a_extTimeStamp)
 set the ext time stamp for the event More...
 
void setEndOfEventWord (uint32_t a_endWord)
 sets the end of event word More...
 
void addTrigTimeStamp (int a_channel, uint16_t a_trigTimeStamp)
 set the trig0 time stamp for the event More...
 
unsigned int getNumChannels () const
 
vector< uint8_t > getChargeChannelList () const
 returns a vector of the channels More...
 
int getNumChargeHits (int a_channel) const
 returns the number of hits associated with a given channel More...
 
int getNumPeakChargeHits (int a_channel) const
 return the numbers of peak charge hits associated with a given channel More...
 
int getNumTimeHits (int a_channel) const
 returns the number of hits associated with a given channel More...
 
int getTotHits () const
 returns to the total numer of hits with charge associated with them More...
 
uint16_t getExtTimeStamp () const
 returns the extended time stamp for the given event More...
 
uint32_t getEndOfEventWord () const
 returns the end of event word from the event More...
 
vector< uint16_t > getTrigTimeStamps (int a_channel) const
 
vector< MDPP16ChargeDatagetCharges (int a_channel) const
 returns a vector of charge values for the given channel
More...
 
vector< MDPP16ChargeDatagetPeakCharges (int a_channel) const
 returns a vector of charge values for the given channel
More...
 
vector< uint16_t > getTimes (int a_channel) const
 returns a vector of charge values for the given channel
More...
 
int getLengthDifference (int a_channel)
 returns the difference between the charge and time vector More...
 
double getGlobalTriggerTime (double a_tdcRes=9.765625e-11)
 returns the global trigger time in s from the beginning of the run More...
 
bool hasMinCharge (int a_threshold=0)
 
bool isGoodEvent ()
 
bool missingData ()
 
bool operator< (MDPP16Event &a_rhs)
 
void setModuleID (uint16_t a_moduleID)
 
uint8_t getModuleID () const
 
virtual std::ostream & print (std::ostream &a_stream=std::cout)
 

Public Attributes

bool m_oddBehavior
 if something went odd in the parse this will be high More...
 

Detailed Description

this class is a container designed to hold an MDPP16 event from any of the firmware it is used generically for either operation mode allowing for storage of either SCP or QDC data in single or multihit mode. The container will scale in size to based on the events present in the listfile It is the first container level that provides encapsulation

Constructor & Destructor Documentation

◆ MDPP16Event()

MDPP16Event::MDPP16Event ( )

default construction leads to an empty container

Member Function Documentation

◆ addCharge()

void MDPP16Event::addCharge ( int  a_channel,
MDPP16ChargeData  a_charge 
)

adds content to the charge map

◆ addCharges()

void MDPP16Event::addCharges ( int  a_channel,
const vector< MDPP16ChargeData > &  a_charges 
)

adds content to the charge map

◆ addPeakCharge()

void MDPP16Event::addPeakCharge ( int  a_channel,
MDPP16ChargeData  a_charge 
)

adds content to the peak charge map

◆ addPeakCharges()

void MDPP16Event::addPeakCharges ( int  a_channel,
const vector< MDPP16ChargeData > &  a_charges 
)

adds content to the peak charge map

◆ addQDCHits()

void MDPP16Event::addQDCHits ( int  a_channel,
const vector< MDPP16ChargeData > &  a_charges,
const vector< uint16_t > &  a_times,
const vector< MDPP16ChargeData > &  a_peakCharges 
)

this adder assumed that there is data in each of the vectors.

adds a series of events to the container this adder assumed that there is data in each of the vectors.

◆ addSCPHits()

void MDPP16Event::addSCPHits ( int  a_channel,
const vector< MDPP16ChargeData > &  a_charges,
const vector< uint16_t > &  a_times 
)

this adder assumed that there is data in each of the vectors.

adds a series of events to the container this adder assumed that there is data in each of the vectors.

◆ addTime()

void MDPP16Event::addTime ( int  a_channel,
uint16_t  a_time 
)

◆ addTimes()

void MDPP16Event::addTimes ( int  a_channel,
const vector< uint16_t > &  a_times 
)

◆ addTrigTimeStamp()

void MDPP16Event::addTrigTimeStamp ( int  a_channel,
uint16_t  a_trigTimeStamp 
)

set the trig0 time stamp for the event

◆ clear()

void MDPP16Event::clear ( )

resets the internal data structures

Here is the caller graph for this function:

◆ getChargeChannelList()

vector< uint8_t > MDPP16Event::getChargeChannelList ( ) const

returns a vector of the channels

Here is the caller graph for this function:

◆ getCharges()

vector< MDPP16ChargeData > MDPP16Event::getCharges ( int  a_channel) const

returns a vector of charge values for the given channel

returns a vector of hits for the given channel vector<T>

Here is the caller graph for this function:

◆ getEndOfEventWord()

uint32_t MDPP16Event::getEndOfEventWord ( ) const

returns the end of event word from the event

Here is the caller graph for this function:

◆ getExtTimeStamp()

uint16_t MDPP16Event::getExtTimeStamp ( ) const

returns the extended time stamp for the given event

Here is the caller graph for this function:

◆ getGlobalTriggerTime()

double MDPP16Event::getGlobalTriggerTime ( double  a_tdcRes = 9.765625e-11)

returns the global trigger time in s from the beginning of the run

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getLengthDifference()

int MDPP16Event::getLengthDifference ( int  a_channel)

returns the difference between the charge and time vector

Here is the call graph for this function:

◆ getModuleID()

uint8_t MDPP16Event::getModuleID ( ) const
Here is the caller graph for this function:

◆ getNumChannels()

unsigned int MDPP16Event::getNumChannels ( ) const

returns the number of channels in the structure inclkuding trigger events

◆ getNumChargeHits()

int MDPP16Event::getNumChargeHits ( int  a_channel) const

returns the number of hits associated with a given channel

returns the number of hits associated with a given channel unsigned int

Here is the caller graph for this function:

◆ getNumPeakChargeHits()

int MDPP16Event::getNumPeakChargeHits ( int  a_channel) const

return the numbers of peak charge hits associated with a given channel

returns the number of hits associated with a given channel unsigned int

◆ getNumTimeHits()

int MDPP16Event::getNumTimeHits ( int  a_channel) const

returns the number of hits associated with a given channel

returns the number of hits associated with a given channel unsigned int

Here is the caller graph for this function:

◆ getPeakCharges()

vector< MDPP16ChargeData > MDPP16Event::getPeakCharges ( int  a_channel) const

returns a vector of charge values for the given channel

returns a vector of hits for the given channel vector<T>

Here is the caller graph for this function:

◆ getTimes()

vector< uint16_t > MDPP16Event::getTimes ( int  a_channel) const

returns a vector of charge values for the given channel

returns a vector of hits for the given channel vector<T>

Here is the caller graph for this function:

◆ getTotHits()

int MDPP16Event::getTotHits ( ) const

returns to the total numer of hits with charge associated with them

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getTrigTimeStamps()

vector< uint16_t > MDPP16Event::getTrigTimeStamps ( int  a_channel) const

returns all the trig time stamps for a given event, returns a null vector if the event doesn't have one correspondig to the specified channel

!!!!!THIS GETTER CAN MODIFY INTERNAL DATA OF THE CLASS!!!! !!!!ONLY USE WITH CAUTION AND AWARE OF POTENTIAL IMPACT!!!! returns a pointer to the base array of the internal data T*
returns all the trig time stamps for a given event, returns a null vector if the event doesn't have one correspondig to the specified channel

Here is the caller graph for this function:

◆ hasMinCharge()

bool MDPP16Event::hasMinCharge ( int  a_threshold = 0)

◆ isGoodEvent()

bool MDPP16Event::isGoodEvent ( )
Here is the call graph for this function:

◆ missingData()

bool MDPP16Event::missingData ( )

this function tests the internal state of the data to see if the correct number of adc and tdc words have been stored

◆ operator<()

bool MDPP16Event::operator< ( MDPP16Event a_rhs)
inline

this operator is used to sort events using std::sort it will sort by time first, then board ID

Here is the call graph for this function:

◆ print()

std::ostream & MDPP16Event::print ( std::ostream &  a_stream = std::cout)
virtual
Here is the call graph for this function:

◆ setEndOfEventWord()

void MDPP16Event::setEndOfEventWord ( uint32_t  a_endWord)

sets the end of event word

◆ setExtTimeStamp()

void MDPP16Event::setExtTimeStamp ( uint16_t  a_extTimeStamp)

set the ext time stamp for the event

set the ext time stamp for the event void

◆ setModuleID()

void MDPP16Event::setModuleID ( uint16_t  a_moduleID)

Member Data Documentation

◆ m_oddBehavior

bool MDPP16Event::m_oddBehavior

if something went odd in the parse this will be high

returns the return !!!!!THIS GETTER CAN MODIFY INTERNAL DATA OF THE CLASS!!!! !!!!ONLY USE WITH CAUTION AND AWARE OF POTENTIAL IMPACT!!!! returns a pointer to the base array of the internal data


The documentation for this class was generated from the following files: