Get all addresses for this event from provider.
Only call registerKeys() if we haven't seen this form before.
82 {
84 return StatusCode::SUCCESS;
85 }
86
88 const DataHeader* dataHeader = nullptr;
89 if (dataHeader == nullptr) {
91 if (!eventDataHeader.isValid()) {
93 return StatusCode::FAILURE;
94 }
95 dataHeader = eventDataHeader.cptr();
96 }
97
99 const AthenaAttributeList* attrList = nullptr;
100 std::string tokenStr;
102 try {
103 tokenStr = (*attrList)["eventRef_secondary"].data<std::string>();
104 ATH_MSG_DEBUG(
"found AthenaAttribute, name = eventRef_secondary = " << tokenStr);
105 } catch (std::exception &e) {
107 return StatusCode::FAILURE;
108 }
109 } else {
111 return StatusCode::FAILURE;
112 }
114 if (!
eventStore()->recordAddress(iop).isSuccess()) {
115 ATH_MSG_ERROR(
"Cannot record address to StoreGate with token string: " << tokenStr);
116 return StatusCode::FAILURE;
117 }
119 }
121 bool doRegister = dataHeader->
dhFormToken().empty() ||
123 ATH_MSG_DEBUG(
"The current Event contains: " << dataHeader->
size() <<
" objects");
124 for (const auto& element : *dataHeader) {
125 if (doRegister) {
127 }
130 delete tadd; tadd = nullptr;
131 } else {
132 ATH_MSG_DEBUG(
"loadAddresses: DataObject address, clid = " << tadd->
clID() <<
", name = " << tadd->
name());
134 tads.push_back(tadd);
135 }
136 }
138 return StatusCode::SUCCESS;
139}
StoreGateSvc * eventStore() const
Return pointer to active event SG.
std::unordered_set< std::string > m_dhFormKeys
Set of DataHeader form keys for which we've already done registerKeys.
Gaudi::Property< std::string > m_attrListKey
Gaudi::Property< std::string > m_dataHeaderKey
static const Guid & null() noexcept
NULL-Guid: static class method.
CLID clID() const
Retrieve string key:
const std::string & name() const
Get the primary (hashed) SG key.
void setProvider(IAddressProvider *provider, StoreID::type storeID)
void registerKeys(const DataHeaderElement &dhe, StoreGateSvc *store)
Register all hash keys for one DH Element.
static const DbType POOL_StorageType
retrieve(aClass, aKey=None)