1#ifndef Podd_THaEvData_h_
2#define Podd_THaEvData_h_
154 static void hexdump(
const char* cbuff,
size_t len);
183 std::unique_ptr<Decoder::THaCrateMap>
fMap;
192 std::array<RocDat_t, Decoder::MAXROC>
rocdat;
195 std::vector<std::unique_ptr<Decoder::THaSlotData>>
crateslot;
260 assert( crate <
rocdat.size() );
310 assert( crate <
rocdat.size() );
317 assert( crate <
rocdat.size() );
323 assert( crate <
rocdat.size() );
327 return (i >=
rocdat[crate].pos &&
431 std::cerr <<
"No module at crate " << crate <<
" slot " << slot << std::endl;
434 return module->HasCapability(type);
441 std::cerr <<
"No module at crate " << crate <<
" slot " << slot << std::endl;
444 return module->IsMultiFunction();
450 if( !module )
return 0;
451 if( module->HasCapability(
type) ) {
452 return module->GetNumEvents(type, chan);
461 if( !module )
return 0;
462 if( module->HasCapability(
type) ) {
463 if( hit >= module->GetNumEvents(
type,
chan) )
return 0;
464 return module->GetData(type, chan, hit);
481 std::cerr <<
"No module at crate " << crate <<
" slot " << slot << std::endl;
484 return module->GetOpt(GetRawData(crate, slot, hit));
#define ClassDef(name, id)
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t index
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t UChar_t len
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t type
UInt_t CountBits(UInt_t startBit=0) const
std::ofstream * fDebugFile
virtual Bool_t DataCached()
virtual Int_t init_slotdata()
void SetEvTime(ULong64_t evtime)
void SetDebug(Int_t level)
std::vector< UShort_t > fSlotClear
virtual ULong64_t GetEvTime() const
void SetVerbose(Int_t level)
UInt_t idx(UInt_t crate, UInt_t slot) const
void EnableScalers(Bool_t enable=true)
virtual Int_t GetHelicity(const TString &) const
UInt_t GetRawData(UInt_t crate, UInt_t slot, UInt_t hit) const
std::vector< std::unique_ptr< Decoder::THaSlotData > > crateslot
Bool_t IsEpicsEvent() const
virtual void PrintOut() const
std::unique_ptr< Decoder::THaCrateMap > fMap
virtual void FindUsedSlots()
UInt_t GetOpt(UInt_t crate, UInt_t slot, UInt_t chan, UInt_t hit) const
virtual Int_t LoadEvent(const UInt_t *evbuffer)=0
static Bool_t GoodCrateSlot(UInt_t crate, UInt_t slot)
virtual Bool_t IsLoadedEpics(const char *) const
std::unique_ptr< THaBenchmark > fBench
static void hexdump(const char *cbuff, size_t len)
Bool_t IsPhysicsTrigger() const
virtual UInt_t GetScaler(UInt_t, UInt_t, UInt_t) const
virtual void SetRunTime(ULong64_t tloc)
Bool_t IsPrescaleEvent() const
void EnablePrescanMode(Bool_t enable=true)
Bool_t PrescanModeEnabled() const
void SetRunInfo(UInt_t num, UInt_t type, ULong64_t tloc)
UInt_t GetNumHits(UInt_t crate, UInt_t slot, UInt_t chan) const
virtual UInt_t GetPrescaleFactor(UInt_t) const
std::vector< UShort_t > fSlotUsed
static const Double_t kBig
static void SetDefaultCrateMapName(const char *name)
Int_t GetDataVersion() const
Bool_t IsPrestartEvent() const
UInt_t GetNumRaw(UInt_t crate, UInt_t slot) const
virtual Int_t SetDataVersion(Int_t version)
virtual TString GetEpicsString(const char *tag, UInt_t event=0) const
static UInt_t GetInstances()
void SetCrateMapName(const char *name)
Bool_t HasCapability(Decoder::EModuleType type, UInt_t crate, UInt_t slot) const
Bool_t HelicityEnabled() const
Decoder::THaCrateMap * GetCrateMap() const
TObject * GetExtra() const
const UInt_t * GetRawDataBuffer() const
virtual void PrintSlotData(UInt_t crate, UInt_t slot) const
void EnableHelicity(Bool_t enable=true)
void SetOrigPS(Int_t event_type)
void EnableBenchmarks(Bool_t enable=true)
Bool_t IsSpecialEvent() const
virtual void makeidx(UInt_t crate, UInt_t slot)
virtual void SetDebugFile(std::ofstream *file)
static Bool_t fgAllowUnimpl
static TString fgDefaultCrateMapName
void SetEpicsEvtType(UInt_t itype)
TString GetOrigPS() const
UInt_t GetNextChan(UInt_t crate, UInt_t slot, UInt_t index) const
UInt_t GetLEbit(UInt_t crate, UInt_t slot, UInt_t chan, UInt_t hit) const
UInt_t GetNumEvents(Decoder::EModuleType type, UInt_t crate, UInt_t slot, UInt_t chan) const
Bool_t ScalersEnabled() const
UInt_t GetNumChan(UInt_t crate, UInt_t slot) const
ULong64_t GetRunTime() const
virtual Decoder::Module * GetModule(UInt_t roc, UInt_t slot) const
UInt_t GetInstance() const
virtual Int_t init_cmap()
UInt_t GetRocLength(UInt_t crate) const
Bool_t IsMultifunction(UInt_t crate, UInt_t slot) const
UInt_t GetRunType() const
virtual Int_t GetHelicity() const
UInt_t GetTrigBits() const
Bool_t InCrate(UInt_t crate, UInt_t i) const
virtual double GetEpicsTime(const char *tag, UInt_t event=0) const
Bool_t GoodIndex(UInt_t crate, UInt_t slot) const
const char * DevType(UInt_t crate, UInt_t slot) const
virtual UInt_t GetScaler(const TString &, UInt_t, UInt_t) const
UInt_t GetEvLength() const
Bool_t IsScalerEvent() const
std::array< RocDat_t, Decoder::MAXROC > rocdat
UInt_t GetData(UInt_t crate, UInt_t slot, UInt_t chan, UInt_t hit) const
virtual double GetEpicsData(const char *tag, UInt_t event=0) const
R__ALWAYS_INLINE Bool_t TestBit(UInt_t f) const
unsigned long long ULong64_t
static const UInt_t TRIGGER_FILE
static const UInt_t PRESTART_EVTYPE
static const UInt_t DETMAP_FILE
static const UInt_t PRESCALE_EVTYPE
static const UInt_t MAXSLOT
static const UInt_t SCALER_EVTYPE
static const UInt_t MAX_PHYS_EVTYPE
static const UInt_t TS_PRESCALE_EVTYPE
static const UInt_t MAXROC