13#define TRG_SHORT_NAMES
14#define TRGCDC_SHORT_NAMES
17#include "trg/cdc/LUT.h"
18#include "trg/cdc/TRGCDCTrack.h"
19#include "trg/cdc/Link.h"
35 return string(
"TRGCDCLUT 1.00");
39 m_data{}, m_bitsize(), m_name()
66 int range = pow(2, nInputBit);
67 openFile.open(filename.c_str());
69 while (getline(openFile, tmpstr) && i < range) {
70 if (!(tmpstr.size() == 0)) {
71 if (tmpstr[0] >=
'0' && tmpstr[0] <=
'9') {
72 tmpint = atoi(tmpstr.c_str());
A class to use LUTs for TRGCDC.
std::vector< int > m_data
LUT data.
int m_bitsize
Input bit size.
std::string m_name
LUT name.
void setDataFile(const std::string &filename, int)
set LUT data.
virtual ~TRGCDCLUT()
Destructor.
std::string version(void) const
returns version.
int getValue(unsigned) const
get LUT Values
static TRGCDCLUT * getLUT(const std::string &filename, int)
get LUT from dictionary, load new LUT if it doesn't exist
static std::map< std::string, TRGCDCLUT > dictionary
list of LUTs, to avoid reading LUT data 2336 times
Abstract base class for different kinds of events.