19#include "GaudiKernel/MsgStream.h"
20#include "GaudiKernel/Bootstrap.h"
21#include "GaudiKernel/PropertyMgr.h"
22#include "GaudiKernel/IJobOptionsSvc.h"
34 IJobOptionsSvc* jobSvc;
35 Gaudi::svcLocator()->service(
"JobOptionsSvc", jobSvc);
37 PropertyMgr m_propMgr;
39 m_propMgr.declareProperty(
"RunMode", m_mode = 2);
40 m_propMgr.declareProperty(
"KeepRandomTrigEvt", m_keepRdm =
true);
41 m_propMgr.declareProperty(
"InputFiles", m_inputFiles);
42 m_propMgr.declareProperty(
"Config4Revise", m_conf4Revise);
44 jobSvc->setMyProperties(
"RawDataInputSvc", &m_propMgr);
70 if ( m_inputFiles.empty() )
return StatusCode::SUCCESS;
73 else if ( m_mode == 3 ) {
74 DistBoss::GetPropertyValue<std::string>(
"DistBoss",
"ServerName", m_evtServer);
83 return StatusCode::FAILURE;
88 m_sds =
new const uint32_t*[64];
89 m_robs =
new const uint32_t*[256];
93 std::ifstream cf(m_conf4Revise.c_str());
98 return StatusCode::SUCCESS;
115 if ( m_sds )
delete m_sds;
116 if ( m_robs )
delete m_robs;
118 return StatusCode::SUCCESS;
131 const uint32_t* ef = 0;
135 std::cerr <<
"Found invalid event (traceback):" << std::endl;
145 f.event_filter_info(ef);
153 if ( ! m_keepRdm && ((*ef)>>31) != 0 ) {
166 uint32_t hv_status = 0;
168 int nsds =
f.children(m_sds, 64);
169 for (
int sdi = 0; sdi < nsds; ++sdi ) {
173 const uint32_t* specific_header;
175 uint32_t source_id_number = sd.
source_id();
176 source_id_number <<= 8;
177 source_id_number >>= 24;
178 switch( source_id_number ) {
180 hv_status |= ((8 | ((*specific_header)&0x7)) << 8);
183 hv_status |= ((8 | ((*specific_header)&0x7)) << 4);
186 hv_status |= (8 | ((*specific_header)&0x7));
199 for (
int robi = 0; robi < nrobs; robi++) {
202 uint32_t* dataptr =
NULL;
208 source_id_number <<= 8;
209 source_id_number >>= 24;
213 if ( source_id_number == 165 ) {
220 switch(source_id_number) {
260 if ( m_reader->
stat()&4 ) {
261 std::cerr << std::endl <<
"reading ifstream error !!!" << std::endl;
268 std::cerr << std::endl <<
"Uncaught eformat issue: " << ex.what() << std::endl;
271 std::cerr << std::endl <<
"Uncaught ERS issue: " << ex.what() << std::endl;
273 catch (std::exception& ex) {
274 std::cerr << std::endl <<
"Uncaught std exception: " << ex.what() << std::endl;
277 std::cerr << std::endl <<
"Uncaught unknown exception" << std::endl;
298 return (m_re = m_onlinere);
TFile f("ana_bhabha660a_dqa_mcPat_zy_old.root")
PthrReaderBufPool< DimRpcReader, 4 > NetDataReader
virtual const uint32_t * nextEvent()=0
virtual uint32_t stat()=0
void addReTofDigi(uint32_t *digi, uint32_t size)
void setFlag1(uint32_t flag1)
void setRunNo(uint32_t run_no)
void addReEtsDigi(uint32_t *digi, uint32_t size)
void addReMdcDigi(uint32_t *digi, uint32_t size)
void addReTrigGTD(uint32_t *digi, uint32_t size)
void addReMucDigi(uint32_t *digi, uint32_t size)
void addReZddDigi(uint32_t *digi, uint32_t size)
void addMcParticle(uint32_t *buf, uint32_t size)
void setTime(uint32_t time)
void setEventNo(uint32_t event_no)
void addReEtfDigi(uint32_t *digi, uint32_t size)
void addReEmcDigi(uint32_t *digi, uint32_t size)
void addReHltRaw(uint32_t *digi, uint32_t size)
virtual void print() const
static SniperJSON load(std::istream &is)