class THaSlotData


   THaSlotData
   Data in one slot of one crate from DAQ.

   THaSlotData contains data from one slot of one crate
   from a CODA event.  Public methods allow to obtain
   raw data for this crate & slot, or to obtain TDC, ADC,
   or scaler data for each channel in the slot.  Methods
   clearEvent() and loadData() should only be used by
   the decoder.  WARNING: For efficiency, only the
   hit counters are zero'd each event, not the data
   arrays, see below.

   author  Robert Michaels (rom@jlab.org)


Function Members (Methods)

public:
THaSlotData()
THaSlotData(const THaSlotData&)
THaSlotData(int crate, int slot)
virtual~THaSlotData()
static TClass*Class()
voidclearEvent()
intcompressdataindex(int numidx)
voiddefine(int crate, int slot, UShort_t nchan = DEFNCHAN, UShort_t ndata = DEFNDATA, UShort_t nhitperchan = DEFNHITCHAN)
const char*devType() const
intgetCrate() const
intgetData(int chan, int hit) const
intgetNextChan(int index) const
intgetNumChan() const
intgetNumHits(int chan) const
intgetNumRaw() const
intgetRawData(int hit) const
intgetRawData(int chan, int hit) const
intgetSlot() const
virtual TClass*IsA() const
intloadData(const char* type, int chan, int dat, int raw)
THaSlotData&operator=(const THaSlotData&)
voidprint() const
virtual voidShowMembers(TMemberInspector& insp, char* parent)
virtual voidStreamer(TBuffer& b)
voidStreamerNVirtual(TBuffer& b)

Data Members

public:
static const intDEFNCHANDefault number of channels
static const intDEFNDATADefault number of data words
static const intDEFNHITCHANDefault number of hits per channel
private:
UShort_tallocdAllocated size of data arrays
UShort_tallociAllocated size of dataindex array
UShort_t*chanindex[channel] gives hitindex
UShort_t*chanlistchanlist[hitindex]
intcrate
int*datadata[hit] (only data bits)
UShort_t*dataindex[idxlist] pointer to rawdata and data
TStringdevice
booldidinitrue if object initialized via define()
UShort_tfirstfreedataidxpointer to first free space in dataindex array
UShort_t*idxlist[channel] pointer to 1st entry in dataindex
UShort_tmaxcNumber of channels for this device
UShort_tmaxdMax number of data words per event
UChar_t*numHitsnumHits[channel]
UChar_t*numMaxHits[channel] current maximum number of hits
UShort_tnumchanhitcan be zero'd by clearEvent each event.
UShort_tnumhitperchanexpected number of hits per channel
UShort_tnumholesdataidx
UShort_tnumrawHit counters (numraw, numHits, numchanhit)
int*rawDatarawData[hit] (all bits)
intslot

Class Charts

Inheritance Chart:
THaSlotData

Function documentation

THaSlotData(const THaSlotData& )
{}
THaSlotData(int crate, int slot)
{}
~THaSlotData()
void define(int crate, int slot, UShort_t nchan = DEFNCHAN, UShort_t ndata = DEFNDATA, UShort_t nhitperchan = DEFNHITCHAN)
 Must call define once if you are really going to use this slot.
 Otherwise its an empty slot which does not use much memory.
int loadData(const char* type, int chan, int dat, int raw)
 loadData loads the data into storage arrays.
void print()
int getRawData(int hit) const
______________ inline functions _____________________________________________
int getRawData(int chan, int hit) const
int getNumHits(int chan) const
 Num hits on a channel
int getNumChan()
 Num unique channels # hit
int getNextChan(int index) const
 List of unique channels hit
int getData(int chan, int hit) const
const char* devType()
void clearEvent()
 Only the minimum is cleared; e.g. data array is not cleared.
 CAUTION: this code is critical for performance
int compressdataindex(int numidx)
THaSlotData(const THaSlotData& )
int getNumRaw()
{ return numraw; }
int getCrate()
{ return crate; }
int getSlot()
{ return slot; }

Last change: Sat Nov 7 21:26:52 2009
Last generated: 2009-11-07 21:26

This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.