ATLAS Offline Software
Loading...
Searching...
No Matches
AthenaKernel/AthenaKernel/IProxyDict.h
Go to the documentation of this file.
1
2
3/*
4 Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
5*/
6
7#ifndef ATHENAKERNEL_IPROXYDICT_H
8# define ATHENAKERNEL_IPROXYDICT_H
9
10// INCLUDES
11#include "SGCore/sgkey_t.h"
17#include "GaudiKernel/INamedInterface.h"
18#include "GaudiKernel/ClassID.h"
19#include <string>
20#include <vector>
21#include <memory>
22
23// DECLARATIONS
24namespace SG {
25 class DataProxy;
26}
27class DataObject;
28class IResetable;
29class IConverter;
30
31
46class IProxyDict : virtual public IStringPool, // not a Gaudi interface
47 virtual public extend_interfaces<IHiveStore, INamedInterface>
48{
49public:
51 virtual ~IProxyDict() override {}
52
60 virtual SG::DataProxy* proxy_exact (SG::sgkey_t sgkey) const = 0;
61
62
76 virtual SG::DataProxy* proxy(const CLID& id,
77 const std::string& key) const = 0;
78
79
86 virtual SG::DataProxy* proxy(const void* const pTransient) const=0;
87
88
92 virtual std::vector<const SG::DataProxy*> proxies() const = 0;
93
94
105 virtual StatusCode addToStore (CLID id, SG::DataProxy* proxy) = 0;
106
107
129 const std::string& key,
130 bool allowMods,
131 bool returnExisting) = 0;
132
133
139 virtual void boundHandle (IResetable* handle);
140
141
147 virtual void unboundHandle (IResetable* handle);
148
149
160 virtual bool tryELRemap (sgkey_t sgkey_in, size_t index_in,
161 sgkey_t& sgkey_out, size_t& index_out);
162
163
179 virtual StatusCode createObj (IConverter* cvt,
180 IOpaqueAddress* addr,
181 DataObject*& refpObject);
182
183
189 virtual IProxyDict* hiveProxyDict() override;
190
191
199 virtual SG::SourceID sourceID (const std::string& key = "EventSelector") const;
200
201
207 virtual StoreID::type storeID() const;
208};
209
210
211#endif // ATHENAKERNEL_IPROXYDICT_H
Type used to identify a metadata source.
Smart pointer to manage DataObject reference counts.
uint32_t CLID
The Class ID type.
Abstract interface for looking up strings/CLIDs in a pool.
virtual bool tryELRemap(sgkey_t sgkey_in, size_t index_in, sgkey_t &sgkey_out, size_t &index_out)
Test to see if the target of an ElementLink has moved.
virtual void boundHandle(IResetable *handle)
Tell the store that a handle has been bound to a proxy.
virtual SG::DataProxy * recordObject(SG::DataObjectSharedPtr< DataObject > obj, const std::string &key, bool allowMods, bool returnExisting)=0
Record an object in the store.
DeclareInterfaceID(IProxyDict, 2, 0)
virtual IProxyDict * hiveProxyDict() override
Return the current event-slot-specific store.
virtual void unboundHandle(IResetable *handle)
Tell the store that a handle has been unbound from a proxy.
virtual StatusCode addToStore(CLID id, SG::DataProxy *proxy)=0
Add a new proxy to the store.
virtual SG::DataProxy * proxy(const CLID &id, const std::string &key) const =0
Get proxy with given id and key.
virtual std::vector< const SG::DataProxy * > proxies() const =0
Return the list of all current proxies in store.
virtual StatusCode createObj(IConverter *cvt, IOpaqueAddress *addr, DataObject *&refpObject)
Call converter to create an object, possibly with locking.
virtual StoreID::type storeID() const
Return the type of this store.
virtual SG::DataProxy * proxy_exact(SG::sgkey_t sgkey) const =0
Get proxy given a hashed key+clid.
virtual SG::DataProxy * proxy(const void *const pTransient) const =0
Get a proxy referencing a given transient object.
virtual SG::SourceID sourceID(const std::string &key="EventSelector") const
Return the metadata source ID for the current event slot.
a resetable object (e.g.
Definition IResetable.h:15
Abstract interface for looking up strings/CLIDs in a pool.
Definition IStringPool.h:28
SG::sgkey_t sgkey_t
Type of the keys.
Definition IStringPool.h:34
Forward declaration.
CxxUtils::RefCountedPtr< T > DataObjectSharedPtr
uint32_t sgkey_t
Type used for hashed StoreGate key+CLID pairs.
Definition sgkey_t.h:32