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];
95 return StatusCode::SUCCESS;
112 if ( m_sds )
delete m_sds;
113 if ( m_robs )
delete m_robs;
115 return StatusCode::SUCCESS;
128 const uint32_t* ef = 0;
132 std::cerr <<
"Found invalid event (traceback):" << std::endl;
142 f.event_filter_info(ef);
150 if ( ! m_keepRdm && ((*ef)>>31) != 0 ) {
163 uint32_t hv_status = 0;
165 int nsds =
f.children(m_sds, 64);
166 for (
int sdi = 0; sdi < nsds; ++sdi ) {
170 const uint32_t* specific_header;
172 uint32_t source_id_number = sd.
source_id();
173 source_id_number <<= 8;
174 source_id_number >>= 24;
175 switch( source_id_number ) {
177 hv_status |= ((8 | ((*specific_header)&0x7)) << 8);
180 hv_status |= ((8 | ((*specific_header)&0x7)) << 4);
183 hv_status |= (8 | ((*specific_header)&0x7));
196 for (
int robi = 0; robi < nrobs; robi++) {
199 uint32_t* dataptr = NULL;
205 source_id_number <<= 8;
206 source_id_number >>= 24;
210 if ( source_id_number == 165 ) {
217 switch(source_id_number) {
257 if ( m_reader->
stat()&4 ) {
258 std::cerr << std::endl <<
"reading ifstream error !!!" << std::endl;
265 std::cerr << std::endl <<
"Uncaught eformat issue: " << ex.what() << std::endl;
268 std::cerr << std::endl <<
"Uncaught ERS issue: " << ex.what() << std::endl;
270 catch (std::exception& ex) {
271 std::cerr << std::endl <<
"Uncaught std exception: " << ex.what() << std::endl;
274 std::cerr << std::endl <<
"Uncaught unknown exception" << std::endl;
295 return (m_re = m_onlinere);
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
TFile f("ana_bhabha660a_dqa_mcPat_zy_old.root")