9 #include "CoralBase/Blob.h"
10 #include "CoralBase/AttributeList.h"
23 return StatusCode::SUCCESS;
32 if (writeHandle.isValid()) {
34 return StatusCode::SUCCESS;
42 return StatusCode::FAILURE;
46 writeHandle.addDependency(readHandle);
53 unsigned nLat=bls.size()/
sizeof(
uint32_t);
54 std::unique_ptr<LArLATOMEMapping> latomeMap=std::make_unique<LArLATOMEMapping>(nLat);
56 for (;chanIt!=chanIt_e;++chanIt) {
60 unsigned nLatome=blobsourceId.size()/
sizeof(
uint32_t);
62 unsigned nChan=blobonlineId.size()/blobsourceId.size();
63 const uint32_t* pblobsourceId=
static_cast<const uint32_t*
>(blobsourceId.startingAddress());
64 const uint32_t* pblobonlineId=
static_cast<const uint32_t*
>(blobonlineId.startingAddress());
67 ATH_MSG_ERROR(
"Number of channels read from DB (" << nChan <<
") does not match expected "
69 return StatusCode::FAILURE;
72 for (
unsigned i=0;
i<nLatome;++
i) {
73 const unsigned sid=pblobsourceId[
i];
75 std::pair<unsigned, std::vector<HWIdentifier> >
entry{sid,{}};
80 entry.second.push_back(hwid);
91 if(writeHandle.record(std::move(latomeMap)).isFailure()) {
92 ATH_MSG_ERROR(
"Could not record LArLATOMEMapping object with "
94 <<
" with EventRange " << writeHandle.getRange()
95 <<
" into Conditions Store");
96 return StatusCode::FAILURE;
98 ATH_MSG_INFO(
"recorded new " << writeHandle.key() <<
" with range " << writeHandle.getRange() <<
" into Conditions Store");
100 return StatusCode::SUCCESS;