48 #include "StTRGReader.h"
50 #include "StDaqLib/GENERIC/EventReader.hh"
51 #include "StDAQReader.h"
52 #include "StStreamFile.h"
59 #include <sys/types.h>
62 #define PP LOG_INFO <<
71 void StTRGReader::Update() {
72 delete fTRGImpReader; fTRGImpReader = 0;
73 fTRGImpReader = ::getTRGReader(fDAQReader->getEventReader());
77 StTRGReader::~StTRGReader() {
81 int StTRGReader::close() {
82 delete fTRGImpReader; fTRGImpReader=0;
86 char StTRGReader::thereIsTriggerData() {
88 ( fDAQReader->getDatFileReader() && OldFormat(fDAQReader->getDatFileReader()->Version()) ))
return 7;
92 const char *StTRGReader::getData()
const
96 data = (
const char*)(fTRGImpReader->pBankTRGD)+40;
97 }
else if ( fDAQReader->getDatFileReader() ) {
98 data = fDAQReader->getDatFileReader()->Record();
103 int StTRGReader::getYear()
const
105 char *dat = (
char*)getData();
115 if (getYear()!=2003)
return 0;
121 if (getYear()!=2004)
return 0;
127 if (getYear()!=2005)
return 0;
133 if (getYear()!=2007)
return 0;
139 if (getYear()!=2008)
return 0;
int YearOfData(char *)
This routine also exists in St_trg_Maker.