9 #include "eformat/SourceIdentifier.h"
15 m_robDataProvider(
"ROBDataProviderSvc",
name),
16 m_ZdcLucrodDecoder(
eformat::FORWARD_ZDC)
27 else ATH_MSG_DEBUG (
" Retrieved service ROBDataProviderSvc ");
31 return StatusCode::SUCCESS;
40 std::vector<const ROBFragment*> listOfRobf;
41 std::vector<unsigned int> ROBIDs;
48 const unsigned int RODSourceIdShifted = eformat::FORWARD_ZDC << 16;
50 for (
unsigned int lucrodModuleNum = 0; lucrodModuleNum < 6; lucrodModuleNum++) {
51 ROBIDs.push_back(RODSourceIdShifted + lucrodModuleNum);
54 ATH_MSG_DEBUG(
"ZdcByteStreamLucrodData::execute::getROBDATA");
57 auto zdcLucrodDataContainer = std::make_unique<ZdcLucrodDataContainer>();
59 ATH_MSG_DEBUG(
"ZdcByteStreamLucrodData::execute::filleContainer");
65 ATH_MSG_DEBUG(
"ZdcByteStreamLucrodData::execute::record m_ZdcLucrodDataContainerKey");
67 sc = h_write.
record(std::move(zdcLucrodDataContainer));
69 ATH_MSG_DEBUG(
"ZdcByteStreamLucrodData::execute::record testing...");
71 if (
sc.isFailure())
ATH_MSG_WARNING(
" Could not record ZdcLucrodDataContainer in StoreGate ");
72 else ATH_MSG_DEBUG (
" ZdcLucrodDataContainer is recorded in StoreGate ");
74 return StatusCode::SUCCESS;
81 size_t nFragments = listOfRobf.size();
85 if (!nFragments)
return StatusCode::SUCCESS;
87 std::vector<const ROBFragment*>::const_iterator rob_it = listOfRobf.begin();
88 std::vector<const ROBFragment*>::const_iterator rob_end = listOfRobf.end();
90 for (; rob_it != rob_end; ++rob_it) {
94 uint32_t robid = (*rob_it)->rod_source_id();
96 ATH_MSG_DEBUG(
" ROB Fragment with ID: 0x" << std::hex << robid << std::dec);
104 if (
sc.isFailure())
ATH_MSG_WARNING(
" Conversion from ByteStream to ZdcLucrodData failed ");
105 else zdcLucrodDataContainer->
push_back(zld);
108 for (
auto zld : *zdcLucrodDataContainer) {zld->
str();}
110 if (zdcLucrodDataContainer->size() == nFragments)
111 return StatusCode::SUCCESS;
113 return StatusCode::FAILURE;
121 return StatusCode::SUCCESS;