![Logo](../../ATLAS-Logo-Square-Blue-RGB.png) |
ATLAS Offline Software
|
Go to the documentation of this file.
19 #include "GaudiKernel/IClassIDSvc.h"
20 #include "GaudiKernel/GenericAddress.h"
21 #include "GaudiKernel/StatusCode.h"
32 m_metaDataStore(
"MetaDataStore",
name),
33 m_clidSvc(
"ClassIDSvc",
name),
49 return(StatusCode::FAILURE);
54 return(StatusCode::FAILURE);
59 return(StatusCode::FAILURE);
61 return(StatusCode::SUCCESS);
77 return(::AthService::queryInterface(riid, ppvInterface));
83 return(StatusCode::SUCCESS);
86 if (!detectorStoreSvc.retrieve().isSuccess()) {
88 return(StatusCode::FAILURE);
92 ATH_MSG_DEBUG(
"Cannot retrieve DataHeader from DetectorStore.");
93 return(StatusCode::SUCCESS);
96 for (
const auto& element : *dataHeader) {
99 delete tadd; tadd =
nullptr;
101 ATH_MSG_DEBUG(
"preLoadAddresses: DataObject address, clid = " << tadd->
clID() <<
", name = " << tadd->
name());
102 tads.push_back(tadd);
106 if (!detectorStoreSvc.release().isSuccess()) {
109 return(StatusCode::SUCCESS);
115 return(StatusCode::SUCCESS);
120 if (dataHeader ==
nullptr) {
122 if (!eventDataHeader.
isValid()) {
124 return(StatusCode::FAILURE);
126 dataHeader = eventDataHeader.
cptr();
131 std::string tokenStr;
134 tokenStr = (*attrList)[
"eventRef_secondary"].data<std::string>();
135 ATH_MSG_DEBUG(
"found AthenaAttribute, name = eventRef_secondary = " << tokenStr);
138 return (StatusCode::FAILURE);
142 return (StatusCode::FAILURE);
145 if (!
eventStore()->recordAddress(iop).isSuccess()) {
146 ATH_MSG_ERROR(
"Cannot record address to StoreGate with token string: " << tokenStr);
147 return(StatusCode::FAILURE);
151 ATH_MSG_DEBUG(
"The current Event contains: " << dataHeader->
size() <<
" objects");
152 for (
const auto& element : *dataHeader) {
155 delete tadd; tadd =
nullptr;
157 ATH_MSG_DEBUG(
"loadAddresses: DataObject address, clid = " << tadd->
clID() <<
", name = " << tadd->
name());
159 tads.push_back(tadd);
164 return(StatusCode::SUCCESS);
169 const EventContext& ) {
170 return(StatusCode::FAILURE);
def retrieve(aClass, aKey=None)
Helper functions for registering hash keys with the SG service.
static const Guid & null()
NULL-Guid: static class method.
def finalize(self)
_info( "content of StoreGate..." ) self.sg.dump()
const_pointer_type cptr()
Dereference the pointer.
ServiceHandle< IClassIDSvc > m_clidSvc
virtual StatusCode updateAddress(StoreID::type storeID, SG::TransientAddress *tad, const EventContext &ctx)
Update a transient address.
ServiceHandle< StoreGateSvc > m_metaDataStore
const std::string & name() const
Get the primary (hashed) SG key.
void registerKeys(const DataHeaderElement &dhe, StoreGateSvc *store)
Register all hash keys for one DH Element.
Handle class for recording to StoreGate.
The Athena Transient Store API.
virtual StatusCode preLoadAddresses(StoreID::type storeID, IAddressProvider::tadList &tads)
Get all addresses from provider.
virtual StatusCode initialize()
Required of all Gaudi Services.
StringProperty m_dataHeaderKey
DataHeaderKey, StoreGate key of event entry object (type DataHeader).
virtual StatusCode finalize()
Required of all Gaudi Services.
::StatusCode StatusCode
StatusCode definition for legacy code.
CLID clID() const
Retrieve string key:
static StoreGateSvc * currentStoreGate()
get current StoreGate
Default, invalid implementation of ClassID_traits.
An AttributeList represents a logical row of attributes in a metadata table. The name and type of eac...
virtual bool isValid() override final
Can the handle be successfully dereferenced?
Gaudi::Property< std::string > m_attrListKey
Attribute list key of a secondary input file.
void setProvider(IAddressProvider *provider, StoreID::type storeID)
virtual StatusCode loadAddresses(StoreID::type storeID, IAddressProvider::tadList &tads)
Get all addresses for this event from provider.
virtual ~AthenaPoolAddressProviderSvc()
Destructor.
An AttributeList represents a logical row of attributes in a metadata table. The name and type of eac...
This file contains the class definition for the AthenaPoolAddressProviderSvc class.
This file contains the class definition for the TokenAddress class.
virtual StatusCode queryInterface(const InterfaceID &riid, void **ppvInterface)
Does this object satisfy a given interface? See Gaudi documentation for details.
This class provides a encapsulation of a GUID/UUID/CLSID/IID data structure (128 bit number).
#define ATH_MSG_WARNING(x)
AthenaPoolAddressProviderSvc(const std::string &name, ISvcLocator *pSvcLocator)
Standard Service Constructor.
std::list< SG::TransientAddress * > tadList
Handle class for reading from StoreGate.
StoreGateSvc * eventStore() const
Return pointer to active event SG.