ATLAS Offline Software
Public Member Functions | List of all members
SGImplSvc Class Referencefinal

The Athena Transient Store API. More...

#include <SGImplSvc.h>

Inheritance diagram for SGImplSvc:
Collaboration diagram for SGImplSvc:

Public Member Functions

 SGImplSvc (const SGImplSvc &)=delete
 
SGImplSvcoperator= (const SGImplSvc &)=delete
 
 DeclareInterfaceID (IProxyDict, 2, 0)
 
 DeclareInterfaceID (INamedInterface, 2, 0)
 
Basic Client Interface: data object access
StatusCode retrieve (CLID clid, SG::detail::IteratorBase &cibegin, SG::detail::IteratorBase &ciend) const
 Retrieve all objects of type T: returns an SG::ConstIterator range. More...
 
Advanced Client Interface: data object registration
StatusCode recordAddress (const std::string &skey, IOpaqueAddress *pAddress, bool clearAddressFlag=true)
 Create a proxy object using an IOpaqueAddress and a transient key. More...
 
StatusCode recordAddress (IOpaqueAddress *pAddress, bool clearAddressFlag=true)
 Create a proxy object using an IOpaqueAddress. More...
 
StatusCode symLink (const void *p2BRegistered, CLID linkID)
 make a soft link to the object T* already registered More...
 
StatusCode symLink (const CLID id, const std::string &key, const CLID linkid)
 make a soft link to the object pointed by id/key More...
 
StatusCode setAlias (CLID clid, const std::string &key, const std::string &aliasKey)
 make an alias to a DataObject (provide data type and old key) More...
 
StatusCode setAlias (const void *p2BAliased, const std::string &aliasKey)
 make an alias to a DataObject (provide only valid pointer) More...
 
StatusCode setAlias (SG::DataProxy *proxy, const std::string &aliasKey)
 make an alias to a DataObject (provide valid proxy) More...
 
StatusCode setConst (const void *pointer)
 prevent downstream clients from modifying the pointed-at dobj More...
 
StatusCode remove (const void *pObject)
 Remove pObject, will remove its proxy if not reset only. More...
 
StatusCode removeDataAndProxy (const void *pObject)
 Remove pObject and its proxy no matter what.
More...
 
bool transientSwap (const CLID &id, const std::string &keyA, const std::string &keyB)
 swap the content of 2 keys payload A indexed by keyA will now be accessed via keyB and vice versa Note that the swap is invalidated at event boundaries and/or when somebody clear the store. More...
 
Advanced Client Interface: data object access
DataObject * typeless_retrievePrivateCopy (const CLID clid, const std::string &key)
 
CLID clid (const std::string &key) const
 Retrieve the main CLID of the object recorded in StoreGate with the given "key" WARNING: slow! More...
 
std::vector< CLIDclids (const std::string &key) const
 Retrieve all the CLID s (including symlinks) of the object recorded in StoreGate with the given "key" WARNING: slow! More...
 
int typeCount (const CLID &id) const
 Return the number of instances of type T (input CLID) More...
 
bool contains (const CLID id, const std::string &key) const
 Look up a keyed object in TDS by CLID. More...
 
bool transientContains (const CLID id, const std::string &key) const
 Look up a transient data object in TDS only by CLID. More...
 
std::string dump () const
 dump objects in store. More...
 
void setStoreID (StoreID::type id)
 set store ID. request forwarded to DataStore: More...
 
StoreID::type storeID () const
 get store ID. request forwarded to DataStore: More...
 
void keys (const CLID &id, std::vector< std::string > &vkeys, bool includeAlias=false, bool onlyValid=true)
 provide list of all StoreGate keys associated with an object. More...
 
virtual ::IProxyDicthiveProxyDict () override final
 implements IHiveStore interface for compat with Hive More...
 
IOVSvc interface
StatusCode regFcn (const CallBackID &c1, const CallBackID &c2, const IOVSvcCallBackFcn &fcn, bool trigger=false)
 register a callback function(2) with an already registered function(1) More...
 
StatusCode regFcn (const std::string &toolName, const CallBackID &c2, const IOVSvcCallBackFcn &fcn, bool trigger=false)
 register a callback function(2) with an already registered AlgTool More...
 
virtual SG::DataProxyproxy (const void *const pTransient) const override final
 get proxy for a given data object address in memory More...
 
virtual SG::DataProxyproxy (const CLID &id) const final
 get default proxy with given id. More...
 
virtual SG::DataProxyproxy (const CLID &id, const std::string &key) const override final
 get proxy with given id and key. Returns 0 to flag failure More...
 
virtual SG::DataProxyproxy (const CLID &id, const char *key) const final
 get proxy with given id and key. More...
 
virtual StatusCode addToStore (CLID id, SG::DataProxy *proxy) override final
 Raw addition of a proxy to the store. More...
 
virtual SG::DataProxyrecordObject (SG::DataObjectSharedPtr< DataObject > obj, const std::string &key, bool allowMods, bool returnExisting) override final
 Record an object in the store. More...
 
virtual SG::DataProxyproxy_exact (SG::sgkey_t sgkey) const override final
 Get proxy given a hashed key+clid. More...
 
more proxy dictionary functionality
virtual SG::DataProxyproxy (const CLID &id, bool checkValid) const
 get default proxy with given id, optionally checking validity. More...
 
virtual SG::DataProxyproxy (const CLID &id, const std::string &key, bool checkValid) const
 get proxy with given id and key, optionally checking validity. More...
 
virtual SG::DataProxyproxy (const CLID &id, const char *key, bool checkValid) const
 get proxy with given id and key, optionally checking validity. More...
 
virtual std::vector< const SG::DataProxy * > proxies () const override final
 return the list of all current proxies in store More...
 
std::vector< CLIDclids () const
 Return all CLIDs in the store. More...
 
SG::DataProxytransientProxy (const CLID &id, const std::string &key) const
 get proxy with given id and key. More...
 
DataObject * accessData (const CLID &id) const
 find proxy and access its data. Returns 0 to flag failure More...
 
DataObject * accessData (const CLID &id, const std::string &key) const
 find proxy and access its data. Returns 0 to flag failure More...
 
void setProxyProviderSvc (IProxyProviderSvc *pPPSvc)
 associate ProxyProviderSvc to this store More...
 
IProxyProviderSvcproxyProviderSvc ()
 Return current ProxyProviderSvc. More...
 
virtual SG::SourceID sourceID (const std::string &key="EventSelector") const override
 Return the metadata source ID for the current event slot. More...
 
ElementLink remapping
void remap_impl (sgkey_t source, sgkey_t target, off_t index_offset)
 Declare a remapping. More...
 
virtual bool tryELRemap (sgkey_t sgkey_in, size_t index_in, sgkey_t &sgkey_out, size_t &index_out) override final
 Test to see if the target of an ElementLink has moved. More...
 
Gaudi Standard Service constructors/destructors
 SGImplSvc (const std::string &name, ISvcLocator *svc)
 Standard Constructor. More...
 
virtual ~SGImplSvc () override final
 Standard Destructor. More...
 
Gaudi IIncidentListener implementation
virtual void handle (const Incident &) override final
 triggered by Incident service More...
 
StatusCode loadEventProxies ()
 load proxies at begin event More...
 

String <-> int key conversions. IStringPool implementation

typedef IStringPool::sgkey_t sgkey_t
 
virtual sgkey_t stringToKey (const std::string &str, CLID clid) override final
 Find the key for a string/CLID pair. More...
 
virtual const std::string * keyToString (sgkey_t key) const override final
 Find the string corresponding to a given key. More...
 
virtual const std::string * keyToString (sgkey_t key, CLID &clid) const override final
 Find the string and CLID corresponding to a given key. More...
 
virtual void registerKey (sgkey_t key, const std::string &str, CLID clidid) override final
 Remember an additional mapping from key to string/CLID. More...
 
bool mergeStringPool (const SGImplSvc &other)
 Merge the string pool from another store into this one. More...
 

Gaudi IService implementation

virtual StatusCode initialize () override final
 Service initialization. More...
 
virtual StatusCode reinitialize () override final
 Service reinitialization. More...
 
virtual StatusCode start () override final
 Service start. More...
 
virtual StatusCode stop () override final
 Service stop. More...
 
virtual StatusCode finalize () override final
 Service finalization. More...
 
virtual StatusCode queryInterface (const InterfaceID &riid, void **ppvInterface) override final
 
static const InterfaceID & interfaceID ()
 Should rather be in ISGImplSvc.h if we had one. More...
 

IHiveStoreMgr implementation

typedef std::recursive_mutex mutex_t
 
typedef std::lock_guard< mutex_tlock_t
 
class IOVDbSvc
 access clearProxyPayload More...
 
class IOVSvcTool
 
class SGDeleteAlg
 
class PerfMon::StorePayloadMon
 
class AthenaOutputStream
 access proxyRange() More...
 
class IOVSvc
 access store() More...
 
class PileUpMergeSvc
 
class StoreGateSvc
 
class SG::VarHandleBase
 access typeless_record More...
 
class ActiveStoreSvc
 
PyObjectAthenaInternal::recordObjectToStore (StoreGateSvc *, PyObject *, PyObject *, bool, bool, bool)
 
void AthenaInternal::py_sg_clearProxyPayload (StoreGateSvc *, SG::DataProxy *)
 
IClassIDSvc * m_pCLIDSvc
 
IConversionSvc * m_pDataLoader
 
ServiceHandle< IProxyProviderSvcm_pPPSHandle
 
IProxyProviderSvcm_pPPS
 
IHistorySvc * m_pHistorySvc
 
SG::DataStorem_pStore
 
std::list< DataObject * > m_trash
 The Recycle Bin. More...
 
ServiceHandle< IIncidentSvc > m_pIncSvc
 property More...
 
bool m_DumpStore
 Dump Property flag: triggers dump() at EndEvent. More...
 
bool m_ActivateHistory
 Activate the history service. More...
 
bool m_DumpArena
 DumpArena Property flag : trigger m_arena->report() at clearStore. More...
 
StringArrayProperty m_folderNameList
 FolderNameList Property. More...
 
IIOVSvcm_pIOVSvc
 
bool m_storeLoaded
 FIXME hack needed by loadEventProxies. More...
 
SG::StringPool m_stringpool
 
SG::RemapImplm_remap_impl
 
SG::Arena m_arena
 Allocation arena to associate with this store. More...
 
int m_slotNumber
 The Hive slot number for this store, or -1 if this isn't a Hive store. More...
 
int m_numSlots
 The total number of slots. 1 if this isn't a Hive store. More...
 
std::map< std::thread::id, std::vector< IResetable * > > m_newBoundHandles
 Keep track of proxies bound since the last call to commitNewDataObjects or clearStore. More...
 
mutex_t m_mutex
 
mutex_t m_remapMutex
 
mutex_t m_stringPoolMutex
 
virtual StatusCode clearStore (bool forceRemove=false) override final
 clear DataStore contents: called by the event loop mgrs More...
 
virtual void commitNewDataObjects () override final
 Reset handles added since the last call to commit. More...
 
void setSlotNumber (int slot, int numSlots)
 Set the Hive slot number for this store. More...
 
virtual void boundHandle (IResetable *handle) override final
 Tell the store that a proxy has been bound to a handle. More...
 
virtual void unboundHandle (IResetable *handle) override final
 Tell the store that a handle has been unbound from a proxy. More...
 
virtual StatusCode createObj (IConverter *cvt, IOpaqueAddress *addr, DataObject *&refpObject) override
 Call converter to create an object, with locking. More...
 
StatusCode record_HistObj (const CLID &id, const std::string &key, const std::string &store, bool allowMods, bool resetOnly=true)
 
StatusCode typeless_record (DataObject *obj, const std::string &key, const void *const raw_ptr, bool allowMods, bool resetOnly=true, bool noHist=false)
 type-less recording of an object with a key, allow possibility of specifying const-access and history record More...
 
StatusCode typeless_overwrite (const CLID &id, DataObject *obj, const std::string &key, const void *const raw_ptr, bool allowMods, bool noHist=false, const std::type_info *tinfo=0)
 same as typeless_record, allows to overwrite an object in memory or on disk More...
 
StatusCode typeless_record (DataObject *obj, const std::string &key, const void *const raw_ptr, bool allowMods, bool resetOnly, bool noHist, const std::type_info *tinfo)
 
StatusCode typeless_record (DataObject *obj, const std::string &key, const void *const raw_ptr, bool allowMods, bool resetOnly, bool noHist, const std::type_info *tinfo, SG::DataProxy **proxy_ret, bool noOverwrite)
 
SG::DataProxyrecord_impl (DataObject *obj, const std::string &key, const void *const raw_ptr, bool allowMods, bool resetOnly, bool allowOverwrite, const std::type_info *tinfo)
 real recording of an object with a key, allow possibility of specifying const-access More...
 
void releaseObject (const CLID &id, const std::string &key)
 release object held by proxy, if any. More...
 
void clearProxyPayload (SG::DataProxy *)
 use to reset a proxy (clearing the data object it contains) Unlike DataProxy::reset this method correctly updates SGSvc internals More...
 
SG::DataProxylocatePersistent (const SG::TransientAddress *tAddr, bool checkValid=false) const
 
StatusCode proxyRange (const CLID &id, SG::ConstProxyIterator &beg, SG::ConstProxyIterator &end) const
 return a range to all proxies of a given CLID More...
 
SG::DataStorestore ()
 
const SG::DataStorestore () const
 
bool isSymLinked (const CLID &linkID, SG::DataProxy *dp)
 
StatusCode addSymLink (const CLID &linkid, SG::DataProxy *dp)
 
StatusCode addAlias (const std::string &aliasKey, SG::DataProxy *dp)
 
std::string createKey (const CLID &dataID)
 creates a key internally if none specified by client More...
 
SG::DataProxysetupProxy (const CLID &dataID, const std::string &gK, DataObject *pDObj, bool allowMods, bool resetOnly)
 try to locate a proxy or create it if needed More...
 
void recycle (DataObject *pBadDObj)
 put a bad (unrecordable) dobj away More...
 
void emptyTrash ()
 throw away bad objects More...
 
bool bindHandleToProxy (const CLID &id, const std::string &key, IResetable *ir, SG::DataProxy *&dp)
 name says it all More...
 
bool bindHandleToProxyAndRegister (const CLID &id, const std::string &key, IResetable *ir, SG::DataProxy *&dp)
 Also do registration with IOVSvc. More...
 
bool bindHandleToProxyAndRegister (const CLID &id, const std::string &key, IResetable *ir, SG::DataProxy *&dp, const CallBackID &c, const IOVSvcCallBackFcn &fcn, bool trigger)
 
StatusCode removeProxy (SG::DataProxy *proxy, const void *pTrans, bool forceRemove=false)
 remove proxy from store, unless it is reset only. More...
 
StatusCode t2pRegister (const void *const pTrans, SG::DataProxy *const pPers)
 forwarded to DataStore More...
 
void t2pRemove (const void *const pTrans)
 forwarded to DataStore More...
 
void msg_update_handler (Gaudi::Details::PropertyBase &outputLevel)
 callback for output level property More...
 
bool associateAux_impl (SG::AuxVectorBase *ptr, const std::string &key, CLID auxclid) const
 
bool associateAux_impl (SG::AuxElement *ptr, const std::string &key, CLID auxclid) const
 
void addAutoSymLinks (const std::string &key, CLID clid, SG::DataProxy *dp, const std::type_info *tinfo, bool warn_nobib=true)
 Add automatically-made symlinks for DP. More...
 
void makeCurrent ()
 The current store is becoming the active store. More...
 
IIOVSvcgetIIOVSvc ()
 get the IOVSvc "just in time" (breaks recursion at initialize) More...
 

Detailed Description

The Athena Transient Store API.

Parameters
Dumpproperty (default false): set to call dump() at EndEvent
FolderNameListproperty (default ""): data folders to be created in this store
Author
ATLAS Collaboration
Id
SGImplSvc.h 797595 2017-02-16 18:36:10Z ssnyder

Definition at line 111 of file SGImplSvc.h.

Member Typedef Documentation

◆ lock_t

typedef std::lock_guard<mutex_t> SGImplSvc::lock_t
private

Definition at line 737 of file SGImplSvc.h.

◆ mutex_t

typedef std::recursive_mutex SGImplSvc::mutex_t
private

Definition at line 736 of file SGImplSvc.h.

◆ sgkey_t

Definition at line 358 of file SGImplSvc.h.

Constructor & Destructor Documentation

◆ SGImplSvc() [1/2]

SGImplSvc::SGImplSvc ( const SGImplSvc )
delete

◆ SGImplSvc() [2/2]

SGImplSvc::SGImplSvc ( const std::string &  name,
ISvcLocator *  svc 
)

Standard Constructor.

Definition at line 89 of file SGImplSvc.cxx.

91  m_pPPSHandle("ProxyProviderSvc", name),
92  m_pPPS(nullptr),
93  m_pHistorySvc(0), m_pStore(new DataStore(*this)),
94  m_pIncSvc("IncidentSvc", name),
95  m_DumpStore(false),
96  m_ActivateHistory(false),
97  m_DumpArena(false),
98  m_pIOVSvc(0),
99  m_storeLoaded(false),
101  m_arena (name),
102  m_slotNumber(-1),
103  m_numSlots(1)
104 {
105  //our properties
106  declareProperty("ProxyProviderSvc", m_pPPSHandle);
107  declareProperty("Dump", m_DumpStore);
108  declareProperty("ActivateHistory", m_ActivateHistory);
109  declareProperty("DumpArena", m_DumpArena);
110  //StoreGateSvc properties
111  declareProperty("IncidentSvc", m_pIncSvc);
112  //add handler for Service base class property
113  m_outputLevel.declareUpdateHandler(&SGImplSvc::msg_update_handler, this);
114 
116  header->addArena (&m_arena);
117 }

◆ ~SGImplSvc()

SGImplSvc::~SGImplSvc ( )
finaloverridevirtual

Standard Destructor.

Definition at line 121 of file SGImplSvc.cxx.

121  {
123  header->delArena (&m_arena);
124 
125  delete m_pStore;
126  delete m_remap_impl;
127 }

Member Function Documentation

◆ accessData() [1/2]

DataObject * SGImplSvc::accessData ( const CLID id) const

find proxy and access its data. Returns 0 to flag failure

Definition at line 1015 of file SGImplSvc.cxx.

1016 {
1017  lock_t lock (m_mutex);
1018  DataProxy* theProxy(proxy(id, true));
1019  return (0 == theProxy) ? 0 : theProxy->accessData();
1020 }

◆ accessData() [2/2]

DataObject * SGImplSvc::accessData ( const CLID id,
const std::string &  key 
) const

find proxy and access its data. Returns 0 to flag failure

Definition at line 1023 of file SGImplSvc.cxx.

1024 {
1025  lock_t lock (m_mutex);
1026  DataProxy* theProxy(proxy(id, key, true));
1027  return (0 == theProxy) ? 0 : theProxy->accessData();
1028 }

◆ addAlias()

StatusCode SGImplSvc::addAlias ( const std::string &  aliasKey,
SG::DataProxy dp 
)
private

Definition at line 730 of file SGImplSvc.cxx.

731 {
732  if (0 == proxy) {
733  warning() << "addAlias: no target DataProxy given, Cannot alias to a non-existing object"
734  << endmsg;
735  return StatusCode::FAILURE;
736  }
737 
738  // add key to proxy and to ProxyStore
739  return m_pStore->addAlias(aliasKey, proxy);
740 }

◆ addAutoSymLinks()

void SGImplSvc::addAutoSymLinks ( const std::string &  key,
CLID  clid,
SG::DataProxy dp,
const std::type_info *  tinfo,
bool  warn_nobib = true 
)
private

Add automatically-made symlinks for DP.

Definition at line 1719 of file SGImplSvc.cxx.

1724 {
1725  // Automatically make all legal base class symlinks
1726  if (!tinfo) {
1728  }
1729  const SG::BaseInfoBase* bib = nullptr;
1730  if (tinfo) {
1731  bib = SG::BaseInfoBase::find (*tinfo);
1732  }
1733  if (!bib) {
1734  // Could succeed where the previous fails if clid for DataVector<T>
1735  // but tinfo is for ConstDataVector<DataVector<T> >.
1736  bib = SG::BaseInfoBase::find (clid);
1737  }
1738  if ( bib ) {
1739  const std::vector<CLID>& bases = bib->get_bases();
1740  for ( std::size_t i = 0, iMax = bases.size(); i < iMax; ++i ) {
1741  if ( bases[i] != clid ) {
1742  if ( addSymLink( bases[i], dp ).isSuccess() ) {
1743  // register with t2p
1744  if (dp->object())
1745  this->t2pRegister( SG::DataProxy_cast( dp, bases[i] ), dp ).ignore();
1746  }
1747  else {
1748  warning() << "record_impl: Doing auto-symlinks for object with CLID "
1749  << clid
1750  << " and SG key " << key
1751  << ": Proxy already set for base CLID " << bases[i]
1752  << "; not making auto-symlink." << endmsg;
1753  }
1754  }
1755  }
1756 
1757  // Handle copy conversions.
1758  {
1759  for (CLID copy_clid : bib->get_copy_conversions()) {
1760  if (m_pStore->addSymLink (copy_clid, dp).isFailure()) {
1761  warning() << "record_impl: Doing auto-symlinks for object with CLID "
1762  << clid
1763  << " and SG key " << key
1764  << ": Proxy already set for copy-conversion CLID "
1765  << copy_clid
1766  << "; not making auto-symlink." << endmsg;
1767  }
1768  }
1769  }
1770  }
1771  else {
1772  if (warn_nobib) {
1773  warning() << "record_impl: Could not find suitable SG::BaseInfoBase for CLID ["
1774  << clid << "] (" << key << ") !\t"
1775  << "No auto-symlink established !"
1776  << endmsg;
1777  }
1778  }
1779 }

◆ addSymLink()

StatusCode SGImplSvc::addSymLink ( const CLID linkid,
SG::DataProxy dp 
)
private

Definition at line 650 of file SGImplSvc.cxx.

651 {
652  if (0 == dp) {
653  warning() << "addSymLink: no target DataProxy found. Sorry, can't link to a non-existing data object"
654  << endmsg;
655  return StatusCode::FAILURE;
656  }
657  StatusCode sc = m_pStore->addSymLink(linkid, dp);
658 
659  // If the symlink is a derived->base conversion, then we may have
660  // a different transient pointer for the symlink.
661  if (sc.isSuccess() && dp->object()) {
662  void* baseptr = SG::DataProxy_cast (dp, linkid);
663  if (baseptr)
664  this->t2pRegister (baseptr, dp).ignore();
665  }
666  return sc;
667 }

◆ addToStore()

StatusCode SGImplSvc::addToStore ( CLID  id,
SG::DataProxy proxy 
)
finaloverridevirtual

Raw addition of a proxy to the store.

Parameters
idCLID of object being added.
proxyproxy to add.

Implements IProxyDict.

Definition at line 836 of file SGImplSvc.cxx.

837 {
838  lock_t lock (m_mutex);
839  return m_pStore->addToStore (id, proxy);
840 }

◆ associateAux_impl() [1/2]

bool SGImplSvc::associateAux_impl ( SG::AuxElement ptr,
const std::string &  key,
CLID  auxclid 
) const
private

Definition at line 1959 of file SGImplSvc.cxx.

1962 {
1963  lock_t lock (m_mutex);
1964  SG_MSG_VERBOSE("called associateAux_impl for key " + key);
1965  // no Aux store set yet
1966  if (!ptr->hasStore()) {
1967  SG::DataProxy* dp = proxy (auxclid, key + "Aux.", true);
1968  if (dp) {
1969  if (!dp->isConst()) {
1970  SG::IAuxStore* pAux = SG::DataProxy_cast<SG::IAuxStore> (dp);
1971  if (pAux) {
1972  ptr->setStore (pAux);
1973  return true;
1974  }
1975  }
1976 
1977  const SG::IConstAuxStore* pAux = SG::DataProxy_cast<SG::IConstAuxStore> (dp);
1978  if (pAux) {
1979  ptr->setStore (pAux);
1980  return true;
1981  }
1982  }
1983  }
1984  return false;
1985 }

◆ associateAux_impl() [2/2]

bool SGImplSvc::associateAux_impl ( SG::AuxVectorBase ptr,
const std::string &  key,
CLID  auxclid 
) const
private

Definition at line 1924 of file SGImplSvc.cxx.

1927 {
1928  // If we already have the aux store (as should usually be the case), return
1929  // without taking out the SG lock. Otherwise, we can deadlock
1930  // if another thread is also trying to dereference a link to the aux store.
1931  // (Should _not_ be holding the SG lock when dereferencing the link!)
1932  if (ptr->hasStore()) return true;
1933 
1934  lock_t lock (m_mutex);
1935  SG_MSG_VERBOSE("called associateAux_impl for key " + key);
1936  // no Aux store set yet
1937  if (!ptr->hasStore()) {
1938  SG::DataProxy* dp = proxy (auxclid, key + "Aux.", true);
1939  if (dp) {
1940  if (!dp->isConst()) {
1941  SG::IAuxStore* pAux = SG::DataProxy_cast<SG::IAuxStore> (dp);
1942  if (pAux) {
1943  ptr->setStore (pAux);
1944  return true;
1945  }
1946  }
1947 
1948  const SG::IConstAuxStore* pAux = SG::DataProxy_cast<SG::IConstAuxStore> (dp);
1949  if (pAux) {
1950  ptr->setStore (pAux);
1951  return true;
1952  }
1953  }
1954  }
1955  return false;
1956 }

◆ bindHandleToProxy()

bool SGImplSvc::bindHandleToProxy ( const CLID id,
const std::string &  key,
IResetable ir,
SG::DataProxy *&  dp 
)
private

name says it all

Definition at line 1398 of file SGImplSvc.cxx.

1400 {
1401  lock_t lock (m_mutex);
1402 
1403  dp = m_pStore->proxy (id, key);
1404  if (dp == nullptr && m_pPPS != nullptr) {
1405  dp = m_pPPS->retrieveProxy(id, key, *m_pStore);
1406  }
1407 
1408  if (0 == dp) return false;
1409 
1410  if (! dp->bindHandle(ir) ) {
1411  fatal() << "DataHandle at " << hex << ir << dec
1412  << " already bound to DataProxy with key " << ir->key()
1413  << ". Cannot bind to proxy " << dp->name() << " as well\n"
1414  << " You have probably registered multiple callbacks via regFcn with the same DataHandle using different keys (DataProxies)\n"
1415  << endmsg;
1416  return false;
1417  }
1418 
1419  //already done in DataHandleBase::setState dp->addRef();
1420 
1421 #ifndef NDEBUG
1422  SG_MSG_DEBUG(" Bound handle " << MSG::hex << ir << " to proxy "
1423  << dp << MSG::dec);
1424 #endif
1425  return true;
1426 }

◆ bindHandleToProxyAndRegister() [1/2]

bool SGImplSvc::bindHandleToProxyAndRegister ( const CLID id,
const std::string &  key,
IResetable ir,
SG::DataProxy *&  dp 
)
private

Also do registration with IOVSvc.

Definition at line 1430 of file SGImplSvc.cxx.

1432 {
1433  lock_t lock (m_mutex);
1434  bool ret = bindHandleToProxy (id, key, ir, dp);
1435  if (ret) {
1437  if (sc.isFailure()) return false;
1438  }
1439  return true;
1440 }

◆ bindHandleToProxyAndRegister() [2/2]

bool SGImplSvc::bindHandleToProxyAndRegister ( const CLID id,
const std::string &  key,
IResetable ir,
SG::DataProxy *&  dp,
const CallBackID c,
const IOVSvcCallBackFcn fcn,
bool  trigger 
)
private

Definition at line 1444 of file SGImplSvc.cxx.

1449 {
1450  lock_t lock (m_mutex);
1451  bool ret = bindHandleToProxy (id, key, ir, dp);
1452  if (ret) {
1454  if (sc.isFailure()) return false;
1455  sc = getIIOVSvc()->regFcn(dp,c,fcn,trigger);
1456  if (sc.isFailure()) return false;
1457  }
1458  return true;
1459 }

◆ boundHandle()

void SGImplSvc::boundHandle ( IResetable handle)
finaloverridevirtual

Tell the store that a proxy has been bound to a handle.

Parameters
proxyThe proxy that was bound. The default implementation does nothing.

Reimplemented from IProxyDict.

Definition at line 1800 of file SGImplSvc.cxx.

1801 {
1802  m_newBoundHandles[std::this_thread::get_id()].push_back (handle);
1803 }

◆ clearProxyPayload()

void SGImplSvc::clearProxyPayload ( SG::DataProxy dp)
private

use to reset a proxy (clearing the data object it contains) Unlike DataProxy::reset this method correctly updates SGSvc internals

Definition at line 1606 of file SGImplSvc.cxx.

1606  {
1607  lock_t lock (m_mutex);
1608 
1609  // Remove transient pointer entries for this proxy.
1610  // But do that only if the proxy has a valid object.
1611  // Otherwise, we could trigger I/O --- which we don't want since it's useless
1612  // (we'd just destroy the object immediately). In some cases it can also
1613  // lead to a deadlock (see ATR-24482).
1614  if (dp->isValidObject()) {
1615  SG::DataProxy::CLIDCont_t clids = dp->transientID();
1616  SG::DataProxy::CLIDCont_t::const_iterator i(clids.begin()), e(clids.end());
1617  while (i != e) {
1619  }
1620  }
1621 
1622  bool hard_reset = (m_numSlots > 1);
1623  dp->reset (hard_reset);
1624 }

◆ clearStore()

StatusCode SGImplSvc::clearStore ( bool  forceRemove = false)
finaloverridevirtual

clear DataStore contents: called by the event loop mgrs

Parameters
forceRemoveif true remove proxies ignoring their resetOnly flag

Implements IHiveStoreMgr.

Definition at line 277 of file SGImplSvc.cxx.

278 {
279  {
280  if (m_DumpArena) {
281  std::ostringstream s;
282  m_arena.report(s);
283  info() << "Report for Arena: " << m_arena.name() << '\n'
284  << s.str() << endmsg;
285  }
286  }
287  {
288  lock_t lock (m_mutex);
289  emptyTrash();
290  for (auto& p : m_newBoundHandles)
291  p.second.clear();
292  assert(m_pStore);
293  debug() << "Clearing store with forceRemove="
294  << forceRemove << endmsg;
295  bool hard_reset = (m_numSlots > 1);
296  m_pStore->clearStore(forceRemove, hard_reset, &msgStream(MSG::DEBUG));
297  m_storeLoaded=false; //FIXME hack needed by loadEventProxies
298  }
299  {
300  lock_t remap_lock (m_remapMutex);
301  m_remap_impl->m_remaps.clear();
302  m_arena.reset();
303  }
304 
305  return StatusCode::SUCCESS;
306 }

◆ clid()

CLID SGImplSvc::clid ( const std::string &  key) const

Retrieve the main CLID of the object recorded in StoreGate with the given "key" WARNING: slow!

Definition at line 1685 of file SGImplSvc.cxx.

1686 {
1687  lock_t lock (m_mutex);
1688  SG::DataStore::ConstStoreIterator s_iter, s_end;
1689  store()->tRange(s_iter, s_end).ignore();
1690 
1691  for ( ; s_iter != s_end; ++s_iter ) {
1692  if ( s_iter->second.find( key ) != s_iter->second.end() ) {
1693  return s_iter->first;
1694  }
1695  }
1696 
1697  return CLID_NULL;
1698 }

◆ clids() [1/2]

std::vector< CLID > SGImplSvc::clids ( ) const

Return all CLIDs in the store.

Definition at line 986 of file SGImplSvc.cxx.

987 {
988  lock_t lock (m_mutex);
989 
990  using std::distance;
991  DataStore::ConstStoreIterator s_iter, s_end;
992  store()->tRange(s_iter, s_end).ignore();
993 
994  std::vector<CLID> clids;
995  clids.reserve( distance( s_iter, s_end ) );
996 
997  for (; s_iter != s_end; ++s_iter ) {
998  const CLID id = s_iter->first;
999  clids.push_back (id);
1000  }
1001 
1002  return clids;
1003 }

◆ clids() [2/2]

std::vector< CLID > SGImplSvc::clids ( const std::string &  key) const

Retrieve all the CLID s (including symlinks) of the object recorded in StoreGate with the given "key" WARNING: slow!

Definition at line 1701 of file SGImplSvc.cxx.

1702 {
1703  lock_t lock (m_mutex);
1704  std::vector<CLID> clids;
1705  SG::DataStore::ConstStoreIterator s_iter, s_end;
1706  store()->tRange(s_iter, s_end).ignore();
1707 
1708  for ( ; s_iter != s_end; ++s_iter ) {
1709  if ( s_iter->second.find( key ) != s_iter->second.end() ) {
1710  clids.push_back(s_iter->first);
1711  }
1712  }
1713 
1714  return clids;
1715 }

◆ commitNewDataObjects()

void SGImplSvc::commitNewDataObjects ( )
finaloverridevirtual

Reset handles added since the last call to commit.

Implements IHiveStoreMgr.

Definition at line 1782 of file SGImplSvc.cxx.

1782  {
1783  lock_t lock (m_mutex);
1784 
1785  // Reset handles added since the last call to commit.
1786  bool hard_reset = (m_numSlots > 1);
1787  std::vector<IResetable*> handles;
1788  m_newBoundHandles[std::this_thread::get_id()].swap (handles);
1789  for (IResetable* h : handles)
1790  h->reset (hard_reset);
1791 }

◆ contains()

bool SGImplSvc::contains ( const CLID  id,
const std::string &  key 
) const

Look up a keyed object in TDS by CLID.

returns false if object not available in TDS or persistent stores Usage: if (!p_store->contains(FooID, "fooKey")) { ... }

Definition at line 750 of file SGImplSvc.cxx.

751 {
752  try {
753  return (0 != proxy(id, key, true));
754  } catch(...) { return false; }
755 }

◆ createKey()

string SGImplSvc::createKey ( const CLID dataID)
private

creates a key internally if none specified by client

Definition at line 268 of file SGImplSvc.cxx.

269 {
270  ostringstream o;
271  o << m_pStore->typeCount(id)+1 << std::ends;
272  string ret(o.str());
273  return ret;
274 }

◆ createObj()

StatusCode SGImplSvc::createObj ( IConverter *  cvt,
IOpaqueAddress *  addr,
DataObject *&  refpObject 
)
overridevirtual

Call converter to create an object, with locking.

Parameters
cvtThe converter to call.
addrOpaque address information for the object to create.
refpObjectReference to location of the pointer of the created object.

This calls the createObj method on cvt to create the referenced transient object, locking the store during the call.

Reimplemented from IProxyDict.

Definition at line 1843 of file SGImplSvc.cxx.

1846 {
1847  // This lock was here originally, but is probably not really needed ---
1848  // both DataProxy and the I/O components have their own locks.
1849  // Further, this was observed to cause deadlocks for the detector store,
1850  // and would in general be expected to be a contention issue.
1851  //lock_t lock (m_mutex);
1852  return cvt->createObj (addr, refpObject);
1853 }

◆ DeclareInterfaceID() [1/2]

IHiveStore::DeclareInterfaceID ( INamedInterface  ,
,
 
)
inherited

◆ DeclareInterfaceID() [2/2]

IProxyDict::DeclareInterfaceID ( IProxyDict  ,
,
 
)
inherited

◆ dump()

string SGImplSvc::dump ( ) const

dump objects in store.

request forwarded to DataStore this is triggered at EndEvent setting the Dump property to true

Definition at line 569 of file SGImplSvc.cxx.

570 {
571  lock_t lock (m_mutex);
572  ostringstream ost;
573  ost << "<<<<<<<<<<<<<<<<< Data Store Dump >>>>>>>>>>>>>>> \n";
574  ost << "SGImplSvc(" + name() + ")::dump():\n";
575 
576  DataStore::ConstStoreIterator s_iter, s_end;
577  store()->tRange(s_iter, s_end).ignore();
578 
579  for (; s_iter != s_end; ++s_iter)
580  {
581 
582  CLID id = s_iter->first;
583  int nProxy = store()->typeCount(id);
584  string tname;
585  m_pCLIDSvc->getTypeNameOfID(id, tname).ignore();
586  ost << "Found " << nProxy << ((nProxy == 1) ? " proxy" : " proxies")
587  << " for ClassID " << id <<" ("<< tname << "): \n";
588 
589  // loop over each type:
590  SG::ConstProxyIterator p_iter = (s_iter->second).begin();
591  SG::ConstProxyIterator p_end = (s_iter->second).end();
592 
593  while (p_iter != p_end) {
594  const DataProxy& dp(*p_iter->second);
595  // ost << " proxy@" << &dp;
596  ost << " flags: ("
597  << setw(7) << (dp.isValid() ? "valid" : "INVALID") << ", "
598  << setw(8) << (dp.isConst() ? "locked" : "UNLOCKED") << ", "
599  << setw(6) << (dp.isResetOnly() ? "reset" : "DELETE")
600  << ") --- data: " << hex << setw(10) << dp.object() << dec
601  << " --- key: " << p_iter->first << '\n';
602  ++p_iter;
603  }
604  }
605  ost << "<<<<<<<<<<<<<<<<<<<<<<<<<>>>>>>>>>>>>>>>>>>>>>>>> \n";
606  string ret(ost.str());
607  return ret;
608 
609 }

◆ emptyTrash()

void SGImplSvc::emptyTrash ( )
private

throw away bad objects

Definition at line 1387 of file SGImplSvc.cxx.

1387  {
1388  lock_t lock (m_mutex);
1389  while (!m_trash.empty()) {
1390  m_trash.front()->release(); //delete the bad data object
1391  m_trash.pop_front(); //remove pointer from list
1392  }
1393 }

◆ finalize()

StatusCode SGImplSvc::finalize ( )
finaloverridevirtual

Service finalization.

Definition at line 309 of file SGImplSvc.cxx.

309  {
310  verbose() << "Finalizing " << name() << endmsg ;
311 
312  // Incident service may not work in finalize.
313  // Clear this, so that we won't try to send an incident from clearStore.
314  (m_pIncSvc.release()).ignore();
315 
316  const bool FORCEREMOVE(true);
317  clearStore(FORCEREMOVE).ignore();
318 
319  //protect against double release
320  if (m_pHistorySvc) {
321  m_pHistorySvc->release();
322  m_pHistorySvc = 0;
323  }
324 
326  delete m_pStore;
327  m_pStore = nullptr;
328  delete m_remap_impl;
329  m_remap_impl = 0;
330  m_arena.erase();
331 
332  return Service::finalize();
333 }

◆ getIIOVSvc()

IIOVSvc * SGImplSvc::getIIOVSvc ( )
private

get the IOVSvc "just in time" (breaks recursion at initialize)

Definition at line 234 of file SGImplSvc.cxx.

234  {
235  // Get hold of the IOVSvc
236  if (0 == m_pIOVSvc && !(service("IOVSvc", m_pIOVSvc)).isSuccess()) {
237  warning() << "Could not locate IOVSvc "
238  << endmsg;
239  }
240  return m_pIOVSvc;
241 }

◆ handle()

void SGImplSvc::handle ( const Incident &  inc)
finaloverridevirtual

triggered by Incident service

Definition at line 244 of file SGImplSvc.cxx.

244  {
245 
246  if (inc.type() == "EndEvent") {
247  if (m_DumpStore) {
248  SG_MSG_DEBUG("Dumping StoreGate Contents");
249  info() << '\n' << dump() << endl
250  << endmsg;
251  }
252  }
253 }

◆ hiveProxyDict()

virtual ::IProxyDict* SGImplSvc::hiveProxyDict ( )
inlinefinaloverridevirtual

implements IHiveStore interface for compat with Hive

Reimplemented from IProxyDict.

Definition at line 232 of file SGImplSvc.h.

232  {
233  return this;
234  }

◆ initialize()

StatusCode SGImplSvc::initialize ( )
finaloverridevirtual

Service initialization.

Definition at line 131 of file SGImplSvc.cxx.

131  {
132 
133  verbose() << "Initializing " << name() << endmsg;
134 
136 
137  if (!m_pStore)
138  m_pStore = new DataStore (*this);
139  if (!m_remap_impl)
141 
142  //properties accessible from now on
143 
145  // If this is the default event store (StoreGateSvc), then declare
146  // our arena as the default for memory allocations.
147  if (this->storeID() == StoreID::EVENT_STORE) {
150  }
151  // set up the incident service:
152  if (!(m_pIncSvc.retrieve()).isSuccess()) {
153  error() << "Could not locate IncidentSvc "
154  << endmsg;
155  return StatusCode::FAILURE;
156  }
157 
158  //start listening to "EndEvent"
159  // const int PRIORITY = 100;
160  // Mother svc should register these incidents
161  // m_pIncSvc->addListener(this, "EndEvent", PRIORITY);
162  // m_pIncSvc->addListener(this, "BeginEvent", PRIORITY);
163 
164  const bool CREATEIF(true);
165  // cache pointer to Persistency Service
166  if (!(service("EventPersistencySvc", m_pDataLoader, CREATEIF)).isSuccess()) {
167  m_pDataLoader = 0;
168  error() << "Could not get pointer to Persistency Service"
169  << endmsg;
170  return StatusCode::FAILURE;
171  }
172 
173  if (!(service("ClassIDSvc", m_pCLIDSvc, CREATEIF)).isSuccess()) {
174  error() << "Could not get pointer to ClassID Service"
175  << endmsg;
176  return StatusCode::FAILURE;
177  }
178 
179  if (!m_pPPSHandle.empty()) {
180  CHECK( m_pPPSHandle.retrieve() );
181  m_pPPS = &*m_pPPSHandle;
182  }
183 
184  if ( m_pPPS && (m_pPPS->preLoadProxies(*m_pStore)).isFailure() )
185  {
186  SG_MSG_DEBUG(" Failed to preLoad proxies");
187  return StatusCode::FAILURE;
188  }
189 
190  // Get hold of History Service
191  if (m_ActivateHistory &&
192  !(service("HistorySvc", m_pHistorySvc, CREATEIF)).isSuccess()) {
193  error() << "Could not locate History Service"
194  << endmsg;
195  return StatusCode::FAILURE;
196  }
197 
198  return StatusCode::SUCCESS;
199 }

◆ interfaceID()

const InterfaceID & SGImplSvc::interfaceID ( )
static

Should rather be in ISGImplSvc.h if we had one.

Definition at line 345 of file SGImplSvc.cxx.

345  {
346  static const InterfaceID IID("SGImplSvc", 1, 0);
347  return IID;
348 }

◆ isSymLinked()

bool SGImplSvc::isSymLinked ( const CLID linkID,
SG::DataProxy dp 
)
private

Definition at line 539 of file SGImplSvc.cxx.

540 {
541  return (0 != dp) ? dp->transientID(linkID) : false;
542 }

◆ keys()

void SGImplSvc::keys ( const CLID id,
std::vector< std::string > &  vkeys,
bool  includeAlias = false,
bool  onlyValid = true 
)

provide list of all StoreGate keys associated with an object.

usage: p_store->keys(CLID, vkeys, optionalFlags);

Parameters
idCLID for which we are requesting list of keys
vkeyswill be filled with the (possibly empty) list of keys
includeAlias(default false) add alias keys as well
onlyValid(default true) add only keys of valid dobjs

Definition at line 530 of file SGImplSvc.cxx.

533 {
534  lock_t lock (m_mutex);
535  return store()->keys(id, vkeys, includeAlias, onlyValid);
536 }

◆ keyToString() [1/2]

const std::string * SGImplSvc::keyToString ( sgkey_t  key) const
finaloverridevirtual

Find the string corresponding to a given key.

Parameters
keyThe key to look up.
Returns
Pointer to the string found, or null. We can find keys as long as the corresponding string was given to either stringToKey() or registerKey().

Implements IStringPool.

Definition at line 1514 of file SGImplSvc.cxx.

1515 {
1516  lock_t lock (m_stringPoolMutex);
1517  return m_stringpool.keyToString (key);
1518 }

◆ keyToString() [2/2]

const std::string * SGImplSvc::keyToString ( sgkey_t  key,
CLID clid 
) const
finaloverridevirtual

Find the string and CLID corresponding to a given key.

Parameters
keyThe key to look up.
clid[out]The found CLID.
Returns
Pointer to the string found, or null. We can find keys as long as the corresponding string was given to either stringToKey() or registerKey().

Implements IStringPool.

Definition at line 1530 of file SGImplSvc.cxx.

1531 {
1532  lock_t lock (m_stringPoolMutex);
1533  return m_stringpool.keyToString (key, clid);
1534 }

◆ loadEventProxies()

StatusCode SGImplSvc::loadEventProxies ( )

load proxies at begin event

Definition at line 255 of file SGImplSvc.cxx.

255  {
256  lock_t lock (m_mutex);
257  StatusCode sc(StatusCode::SUCCESS);
258  //FIXME this should probably be dealt with by the providers
259  if (0 != m_pPPS && !m_storeLoaded) {
260  m_storeLoaded = true;
262  }
263  return sc;
264 }

◆ locatePersistent()

DataProxy * SGImplSvc::locatePersistent ( const SG::TransientAddress tAddr,
bool  checkValid = false 
) const
private

Definition at line 1268 of file SGImplSvc.cxx.

1270 {
1271  DataProxy* dp = m_pStore->proxy(tAddr);
1272 
1273  if (checkValid && 0 != dp) {
1274  return dp->isValid() ? dp : 0;
1275  } else {
1276  return dp;
1277  }
1278 }

◆ makeCurrent()

void SGImplSvc::makeCurrent ( )
private

The current store is becoming the active store.

Switch the allocation arena, if needed. Only intended to be called by ActiveStoreSvc.

Switch the allocation arena, if needed, and call SG::CurrentEventStore::setStore.

Definition at line 1824 of file SGImplSvc.cxx.

1825 {
1826  lock_t lock (m_mutex);
1827  m_arena.makeCurrent();
1829 }

◆ mergeStringPool()

bool SGImplSvc::mergeStringPool ( const SGImplSvc other)

Merge the string pool from another store into this one.

Parameters
otherThe other store.

In case of collisions, the colliding entries are skipped, and false is returned. If no collisions, then true is returned.

Definition at line 1572 of file SGImplSvc.cxx.

1573 {
1574  // We should hold m_stringPoolMutex before touching the pool.
1575  // But if we acquire the locks for both this and the other store,
1576  // we risk a deadlock. So first copy the other pool, so that we
1577  // don't need to hold both locks at the same time.
1579  {
1580  lock_t lock (other.m_stringPoolMutex);
1581  tmp = other.m_stringpool;
1582  }
1583  lock_t lock (m_stringPoolMutex);
1584  return m_stringpool.merge (tmp);
1585 }

◆ msg_update_handler()

void SGImplSvc::msg_update_handler ( Gaudi::Details::PropertyBase &  outputLevel)
private

callback for output level property

Definition at line 1328 of file SGImplSvc.cxx.

1329 {
1330  setUpMessaging();
1331  updateMsgStreamOutputLevel( outputLevel() );
1332  msgSvc()->setOutputLevel(name(), outputLevel());
1333 }

◆ operator=()

SGImplSvc& SGImplSvc::operator= ( const SGImplSvc )
delete

◆ proxies()

std::vector< const SG::DataProxy * > SGImplSvc::proxies ( ) const
finaloverridevirtual

return the list of all current proxies in store

Implements IProxyDict.

Definition at line 976 of file SGImplSvc.cxx.

977 {
978  lock_t lock (m_mutex);
979  const std::vector<SG::DataProxy*>& proxies = store()->proxies();
980  std::vector<const SG::DataProxy*> ret (proxies.begin(), proxies.end());
981  return ret;
982 }

◆ proxy() [1/7]

DataProxy * SGImplSvc::proxy ( const CLID id) const
finalvirtual

get default proxy with given id.

Returns 0 to flag failure Deprecated for the event store.

Definition at line 777 of file SGImplSvc.cxx.

778 {
779  return proxy(id, false);
780 }

◆ proxy() [2/7]

DataProxy * SGImplSvc::proxy ( const CLID id,
bool  checkValid 
) const
virtual

get default proxy with given id, optionally checking validity.

Returns
0 to flag failure

Check if it is valid

Definition at line 783 of file SGImplSvc.cxx.

784 {
785  DataProxy* dp = nullptr;
786  {
787  lock_t lock (m_mutex);
788  dp = m_pStore->proxy(id);
789  if (0 == dp && 0 != m_pPPS) {
791  dp = m_pPPS->retrieveProxy(id, string("DEFAULT"), *pStore);
792  }
793  }
795  // Be sure to release the lock before this.
796  // isValid() may call back to the store, so we could otherwise deadlock..
797  if (checkValid && 0 != dp) {
798  // FIXME: For keyless retrieve, this checks only the first instance
799  // of the CLID in store. If that happens to be invalid, but the second
800  // is valid - this does not work (when checkValid is requested).
801  return dp->isValid() ? dp : 0;
802  }
803  return dp;
804 }

◆ proxy() [3/7]

virtual SG::DataProxy* SGImplSvc::proxy ( const CLID id,
const char *  key 
) const
inlinefinalvirtual

get proxy with given id and key.

Returns 0 to flag failure (overload to prevent a char* to be interpreted as a bool.)

Definition at line 268 of file SGImplSvc.h.

269  { return this->proxy(id, std::string(key)); }

◆ proxy() [4/7]

virtual SG::DataProxy* SGImplSvc::proxy ( const CLID id,
const char *  key,
bool  checkValid 
) const
inlinevirtual

get proxy with given id and key, optionally checking validity.

Returns
0 to flag failure (overload to prevent a char* to be interpreted as a bool.)

Definition at line 320 of file SGImplSvc.h.

321  { return this->proxy(id, std::string(key), checkValid); }

◆ proxy() [5/7]

DataProxy * SGImplSvc::proxy ( const CLID id,
const std::string &  key 
) const
finaloverridevirtual

get proxy with given id and key. Returns 0 to flag failure

Implements IProxyDict.

Definition at line 807 of file SGImplSvc.cxx.

808 {
809  return proxy(id, key, false);
810 }

◆ proxy() [6/7]

DataProxy * SGImplSvc::proxy ( const CLID id,
const std::string &  key,
bool  checkValid 
) const
virtual

get proxy with given id and key, optionally checking validity.

Returns
0 to flag failure

Definition at line 813 of file SGImplSvc.cxx.

814 {
815  DataProxy* dp = nullptr;
816  {
817  lock_t lock (m_mutex);
818  dp = m_pStore->proxy(id, key);
819  if (0 == dp && 0 != m_pPPS) {
821  dp = m_pPPS->retrieveProxy(id, key, *pStore);
822  }
823  }
824  // Be sure to release the lock before this.
825  // isValid() may call back to the store, so we could otherwise deadlock..
826  if (checkValid && 0 != dp && !(dp->isValid())) dp = 0;
827  return dp;
828 }

◆ proxy() [7/7]

DataProxy * SGImplSvc::proxy ( const void *const  pTransient) const
finaloverridevirtual

get proxy for a given data object address in memory

Implements IProxyDict.

Definition at line 768 of file SGImplSvc.cxx.

769 {
770  // No lock needed here --- the T2pmap held by DataStore has its own locking
771  // (and we were seeing contention here).
772  //lock_t lock (m_mutex);
773  return m_pStore->locatePersistent(pTransient);
774 }

◆ proxy_exact()

SG::DataProxy * SGImplSvc::proxy_exact ( SG::sgkey_t  sgkey) const
finaloverridevirtual

Get proxy given a hashed key+clid.

Find an exact match; no handling of aliases, etc. Returns 0 to flag failure.

Implements IProxyDict.

Definition at line 953 of file SGImplSvc.cxx.

954 {
956 }

◆ proxyProviderSvc()

IProxyProviderSvc* SGImplSvc::proxyProviderSvc ( )

Return current ProxyProviderSvc.

◆ proxyRange()

StatusCode SGImplSvc::proxyRange ( const CLID id,
SG::ConstProxyIterator beg,
SG::ConstProxyIterator end 
) const
private

return a range to all proxies of a given CLID

Definition at line 1336 of file SGImplSvc.cxx.

1338  {
1339  lock_t lock (m_mutex);
1340  return m_pStore->pRange(id,begin,end);
1341 }

◆ queryInterface()

StatusCode SGImplSvc::queryInterface ( const InterfaceID &  riid,
void **  ppvInterface 
)
finaloverridevirtual

Definition at line 355 of file SGImplSvc.cxx.

356 {
357  if ( IProxyDict::interfaceID().versionMatch(riid) ) {
358  *ppvInterface = (IProxyDict*)this;
359  }
360  else if ( IProxyDict::interfaceID().versionMatch(riid) ) {
361  *ppvInterface = (IProxyDict*)this;
362  }
363  else if ( IHiveStoreMgr::interfaceID().versionMatch(riid) ) {
364  *ppvInterface = (IHiveStoreMgr*)this;
365  }
366  else if ( interfaceID().versionMatch(riid) ) {
367  // In principle this should be cast to ISGImplSvc*. However, there
368  // is an anomaly in that existing clients are using the concrete StoreGate
369  // interface instead of an abstract ISGImplSvc interface.
370  *ppvInterface = (SGImplSvc*)this;
371  } else {
372  // Interface is not directly available: try out a base class
373  return Service::queryInterface(riid, ppvInterface);
374  }
375  addRef();
376  return StatusCode::SUCCESS;
377 }

◆ record_HistObj()

StatusCode SGImplSvc::record_HistObj ( const CLID id,
const std::string &  key,
const std::string &  store,
bool  allowMods,
bool  resetOnly = true 
)
private

Definition at line 1464 of file SGImplSvc.cxx.

1466  {
1467 
1468  assert(m_pHistorySvc);
1469 
1470  DataHistory *dho;
1471  dho = m_pHistorySvc->createDataHistoryObj( id, key, store );
1472 
1473  std::string idname;
1474  StatusCode sc = m_pCLIDSvc->getTypeNameOfID(id, idname);
1475  if (sc.isFailure() || idname.empty() ) {
1476  idname = std::to_string(id);
1477  }
1478  idname += '/';
1479  idname += key;
1480 
1481  DataObject* obj = SG::asStorable(dho);
1482 
1483  const bool ALLOWOVERWRITE(false);
1484  if (record_impl(obj, idname, dho, allowMods, resetOnly, ALLOWOVERWRITE,
1485  &typeid(DataHistory)) == nullptr)
1486  return StatusCode::FAILURE;
1487  return StatusCode::SUCCESS;
1488 }

◆ record_impl()

SG::DataProxy * SGImplSvc::record_impl ( DataObject *  obj,
const std::string &  key,
const void *const  raw_ptr,
bool  allowMods,
bool  resetOnly,
bool  allowOverwrite,
const std::type_info *  tinfo 
)
private

real recording of an object with a key, allow possibility of specifying const-access

Definition at line 1140 of file SGImplSvc.cxx.

1144 {
1145  CLID clid = pDObj->clID();
1146  std::string rawKey(key);
1147  bool isVKey(SG::VersionedKey::isVersionedKey(key));
1148  if (isVKey) {
1149  //FIXME VersionedKeys will need to be handled more efficiently
1150  SG::VersionedKey vk(rawKey);
1151  DataProxy *dp(proxy(clid, vk.key()));
1152  if (dp) {
1153  //proxies primary key
1154  const std::string& pTAName(dp->name());
1155  //original key as versioned
1156  SG::VersionedKey primaryVK(pTAName);
1157 
1158  //if the existing matching object has no version
1159  //create a versioned alias for the original unversioned key
1160  //so it will remain accessible
1161  if (!SG::VersionedKey::isVersionedKey(pTAName)) {
1162  if (!(this->addAlias(primaryVK.rawVersionKey(), dp)).isSuccess()) {
1163  warning() << "record_impl: Could not setup alias key "
1164  << primaryVK.rawVersionKey()
1165  << " for unversioned object " << pTAName
1166  << endmsg;
1167  return nullptr;
1168  }
1169  }
1170  if (vk.isAuto()) {
1171  //make a new versioned key incrementing the existing version
1172  SG::VersionedKey newVK(primaryVK.key(), primaryVK.version()+1);
1173  //FIXME this will fail in a confusing way if version+1 is in use
1174  //FIXME need a better error message below, probably looking at all
1175  //FIXME aliases
1176  rawKey = newVK.rawVersionKey();
1177  }
1178  }
1179  }
1180  if (!allowOverwrite && m_pPPS) {
1181  //do not overwrite a persistent object
1182  DataProxy* dp = m_pStore->proxy (clid, rawKey);
1183  if (!dp) {
1184  dp = m_pPPS->retrieveProxy(clid, rawKey, *m_pStore);
1185  }
1186  if (dp && dp->provider()) {
1187  std::string clidTypeName;
1188  m_pCLIDSvc->getTypeNameOfID(clid, clidTypeName).ignore();
1189  warning() << "record_impl: you are recording an object with key "
1190  << rawKey << ", type " << clidTypeName
1191  << " (CLID " << clid << ')'
1192  << "\n There is already a persistent version of this object. Recording a duplicate may lead to unreproducible results and it is deprecated."
1193  << endmsg;
1194  }
1195  }
1196  //now check whether raw_ptr has already been recorded
1197  //We need to do this before we create the bucket, the proxy etc
1198  SG::DataProxy* dp(proxy(raw_ptr));
1199  if (0 != dp) {
1200  std::string clidTypeName;
1201  m_pCLIDSvc->getTypeNameOfID(clid, clidTypeName).ignore();
1202  warning() << "record_impl: failed for key="<< rawKey << ", type "
1203  << clidTypeName
1204  << " (CLID " << clid << ')'
1205  << "\n object @" << raw_ptr
1206  << " already in store with key="<< dp->name()
1207  << ". Will not record a duplicate! "
1208  << endmsg;
1209  if (pDObj != dp->object()) {
1210  DataBucketBase* pDBB(dynamic_cast<DataBucketBase*>(pDObj));
1211  if (!pDBB) std::abort();
1212  pDBB->relinquish(); //don't own the data obj already recorded!
1213  }
1214  this->recycle(pDObj);
1215  return nullptr;
1216  }
1217 
1218 
1219  // setup the proxy
1220  dp = setupProxy( clid, rawKey, pDObj, allowMods, resetOnly );
1221  if ( 0 == dp ) {
1222  std::string clidTypeName;
1223  m_pCLIDSvc->getTypeNameOfID(clid, clidTypeName).ignore();
1224  warning() << "record_impl: Problem setting up the proxy for object @"
1225  << raw_ptr
1226  << "\n recorded with key " << rawKey
1227  << " of type " << clidTypeName
1228  << " (CLID " << clid << ") in DataObject @" << pDObj
1229  << endmsg;
1230 
1231  return nullptr;
1232  }
1233 
1234  // record in t2p:
1235  if ( !(this->t2pRegister( raw_ptr, dp )).isSuccess() ) {
1236  std::string clidTypeName;
1237  m_pCLIDSvc->getTypeNameOfID(clid, clidTypeName).ignore();
1238  warning() << "record_impl: can not add to t2p map object @" <<raw_ptr
1239  << "\n with key " << rawKey
1240  << " of type " << clidTypeName
1241  << " (CLID " << clid << ')'
1242  << endmsg;
1243  return nullptr;
1244  }
1245 
1246  addAutoSymLinks (rawKey, clid, dp, tinfo);
1247 
1248  //handle versionedKeys: we register an alias with the "true" key
1249  //unless an object as already been recorded with that key.
1250  //Notice that addAlias overwrites any existing alias, so a generic
1251  //retrieve will always return the last version added
1252  //FIXME not the one with the highest version
1253  if (isVKey) {
1254  SG::VersionedKey vk(rawKey);
1255  if (!(this->addAlias(vk.key(), dp)).isSuccess()) {
1256  warning() << "record_impl: Could not setup alias key " << vk.key()
1257  << " for VersionedKey " << rawKey
1258  << ". Generic access to this object with clid" << clid
1259  << " will not work"
1260  << endmsg;
1261  }
1262  }
1263 
1264  return dp;
1265 }

◆ recordAddress() [1/2]

StatusCode SGImplSvc::recordAddress ( const std::string &  skey,
IOpaqueAddress *  pAddress,
bool  clearAddressFlag = true 
)

Create a proxy object using an IOpaqueAddress and a transient key.

Definition at line 383 of file SGImplSvc.cxx.

386 {
387  lock_t lock (m_mutex);
388  assert(0 != pAddress);
389  CLID dataID = pAddress->clID();
390 
391  if (dataID == 0)
392  {
393  warning() << "recordAddress: Invalid Class ID found in IOpaqueAddress @"
394  << pAddress << ". IOA will not be recorded"
395  << endmsg;
396  return StatusCode::FAILURE;
397  }
398 
399  //do not overwrite a persistent object
400  if (m_pPPS) {
401  DataProxy* dp = m_pStore->proxy (dataID, skey);
402  if (!dp) {
403  dp = m_pPPS->retrieveProxy(dataID, skey, *m_pStore);
404  }
405  if (dp && dp->provider()) {
406  std::string clidTypeName;
407  m_pCLIDSvc->getTypeNameOfID(dataID, clidTypeName).ignore();
408  warning() << "recordAddress: failed for key="<< skey << ", type "
409  << clidTypeName
410  << " (CLID " << dataID << ')'
411  << "\n there is already a persistent version of this object. Will not record a duplicate! "
412  << endmsg;
413  return StatusCode::FAILURE;
414  }
415  }
416 
417  // Check if a key already exists
418  DataProxy* dp = m_pStore->proxy_exact(dataID, skey);
419  if (0 == dp && 0 != m_pPPS) {
420  dp = m_pPPS->retrieveProxy(dataID, skey, *m_pStore);
421  }
422 
423  // Now treat the various cases:
424  if (0 == dp)
425  {
426  // create the proxy object and register it
427  dp = new DataProxy (TransientAddress (dataID, skey,
428  pAddress, clearAddressFlag),
429  m_pDataLoader, true, true);
430  m_pStore->addToStore(dataID, dp).ignore();
431 
432  addAutoSymLinks (skey, dataID, dp, 0, false);
433  }
434  else if ((0 != dp) && (0 == dp->address()))
435  // Note: intentionally not checking dp->isValidAddress()
436  {
437  // Update proxy with IOpaqueAddress
438  dp->setAddress(pAddress);
439  }
440  else
441  {
442  string errType;
443  m_pCLIDSvc->getTypeNameOfID(dataID, errType).ignore();
444  warning() << "recordAddress: preexisting proxy @" << dp
445  << " with non-NULL IOA found for key "
446  << skey << " type " << errType << " (" << dataID << "). \n"
447  << "Cannot record IOpaqueAddress @" << pAddress
448  << endmsg;
449  return StatusCode::FAILURE;
450  }
451 
452  return StatusCode::SUCCESS;
453 
454 }

◆ recordAddress() [2/2]

StatusCode SGImplSvc::recordAddress ( IOpaqueAddress *  pAddress,
bool  clearAddressFlag = true 
)

Create a proxy object using an IOpaqueAddress.

Definition at line 460 of file SGImplSvc.cxx.

461 {
462  lock_t lock (m_mutex);
463  assert(0 != pAddress);
464 
465  CLID dataID = pAddress->clID();
466 
467  string gK = (pAddress->par())[1]; // transient name by convention
468  if (gK.empty()) gK = (pAddress->par())[0]; // FIXME backward compatibility
469  if (gK.empty()) gK = createKey(dataID);
470 
471  return this->recordAddress(gK, pAddress, clearAddressFlag);
472 }

◆ recordObject()

SG::DataProxy * SGImplSvc::recordObject ( SG::DataObjectSharedPtr< DataObject >  obj,
const std::string &  key,
bool  allowMods,
bool  returnExisting 
)
finaloverridevirtual

Record an object in the store.

Parameters
objThe data object to store.
keyThe key as which it should be stored.
allowModsIf false, the object will be recorded as const.
returnExistingIf true, return proxy if this key already exists. If the object has been recorded under a different key, then make an alias. If the object has been recorded under a different clid, then make a link.

Full-blown record. obj should usually be something deriving from SG::DataBucket.

Returns the proxy for the recorded object; nullptr on failure. If the requested CLID/key combination already exists in the store, the behavior is controlled by returnExisting. If true, then the existing proxy is returned; otherwise, nullptr is returned. In either case, obj is destroyed.

Implements IProxyDict.

Definition at line 863 of file SGImplSvc.cxx.

867 {
868  lock_t lock (m_mutex);
869  const void* raw_ptr = obj.get();
870  const std::type_info* tinfo = nullptr;
871 
872  if (DataBucketBase* bucket = dynamic_cast<DataBucketBase*> (obj.get())) {
873  raw_ptr = bucket->object();
874  tinfo = &bucket->tinfo();
875  }
876 
877  if (returnExisting) {
878  SG::DataProxy* proxy = this->proxy (obj->clID(), key);
879  if (proxy && proxy->isValid()) return proxy;
880 
881  // Look for the same object recorded under a different key/clid.
882  proxy = this->proxy (raw_ptr);
883  if (proxy && proxy->isValid()) {
884  if (proxy->transientID (obj->clID())) {
885  // CLID matches. Make an alias.
886  if (addAlias (key, proxy).isFailure()) {
887  CLID clid = proxy->clID();
888  std::string clidTypeName;
889  m_pCLIDSvc->getTypeNameOfID(clid, clidTypeName).ignore();
890  warning() << "SGImplSvc::recordObject: addAlias fails for object "
891  << clid << "[" << clidTypeName << "] " << proxy->name()
892  << " and new key " << key
893  << endmsg;
894 
895  proxy = nullptr;
896  }
897  }
898 
899  else if (key == proxy->name() ||
900  proxy->alias().count (key) > 0)
901  {
902  // key matches. Make a symlink.
903  if (addSymLink (obj->clID(), proxy).isFailure()) {
904  CLID clid = proxy->clID();
905  std::string clidTypeName;
906  m_pCLIDSvc->getTypeNameOfID(clid, clidTypeName).ignore();
907  CLID newclid = obj->clID();
908  std::string newclidTypeName;
909  m_pCLIDSvc->getTypeNameOfID(newclid, newclidTypeName).ignore();
910  error() << "SGImplSvc::recordObject: addSymLink fails for object "
911  << clid << "[" << clidTypeName << "] " << proxy->name()
912  << " and new clid " << newclid << "[" << newclidTypeName << "]"
913  << endmsg;
914  proxy = nullptr;
915  }
916  }
917 
918  else {
919  CLID clid = proxy->clID();
920  std::string clidTypeName;
921  m_pCLIDSvc->getTypeNameOfID(clid, clidTypeName).ignore();
922  CLID newclid = obj->clID();
923  std::string newclidTypeName;
924  m_pCLIDSvc->getTypeNameOfID(newclid, newclidTypeName).ignore();
925  error() << "SGImplSvc::recordObject: existing object found with "
926  << clid << "[" << clidTypeName << "] " << proxy->name()
927  << " but neither clid " << newclid << "[" << newclidTypeName << "]"
928  << " nor key " << key << " match."
929  << endmsg;
930  proxy = nullptr;
931  }
932 
933  return proxy;
934  }
935  }
936 
937  const bool resetOnly = true;
938  const bool noHist = false;
939  SG::DataProxy* proxy = nullptr;
940  if (this->typeless_record (obj.get(), key, raw_ptr,
941  allowMods, resetOnly, noHist, tinfo,
942  &proxy, true).isFailure())
943  {
944  return nullptr;
945  }
946  return proxy;
947 }

◆ recycle()

void SGImplSvc::recycle ( DataObject *  pBadDObj)
private

put a bad (unrecordable) dobj away

Definition at line 1380 of file SGImplSvc.cxx.

1380  {
1381  assert(pBadDObj);
1382  pBadDObj->addRef();
1383  m_trash.push_back(pBadDObj);
1384 }

◆ regFcn() [1/2]

StatusCode SGImplSvc::regFcn ( const CallBackID c1,
const CallBackID c2,
const IOVSvcCallBackFcn fcn,
bool  trigger = false 
)

register a callback function(2) with an already registered function(1)

Definition at line 546 of file SGImplSvc.cxx.

550 {
551  lock_t lock (m_mutex);
552  return ( getIIOVSvc()->regFcn(c1,c2,fcn,trigger) );
553 }

◆ regFcn() [2/2]

StatusCode SGImplSvc::regFcn ( const std::string &  toolName,
const CallBackID c2,
const IOVSvcCallBackFcn fcn,
bool  trigger = false 
)

register a callback function(2) with an already registered AlgTool

Definition at line 557 of file SGImplSvc.cxx.

561 {
562  lock_t lock (m_mutex);
563  return ( getIIOVSvc()->regFcn(toolName,c2,fcn,trigger) );
564 }

◆ registerKey()

void SGImplSvc::registerKey ( sgkey_t  key,
const std::string &  str,
CLID  clid 
)
finaloverridevirtual

Remember an additional mapping from key to string/CLID.

Parameters
keyThe key to enter.
strThe string to enter.
clidThe CLID associated with the string.
Returns
True if successful; false if the key already corresponds to a different string.

This registers an additional mapping from a key to a string; it can be found later through lookup() on the string. Logs an error if key already corresponds to a different string.

Implements IStringPool.

Definition at line 1549 of file SGImplSvc.cxx.

1552 {
1553  lock_t lock (m_stringPoolMutex);
1554  if (!m_stringpool.registerKey (key, str, clid)) {
1555  CLID clid2;
1556  const std::string* str2 = m_stringpool.keyToString (key, clid2);
1557  REPORT_MESSAGE (MSG::WARNING) << "The numeric key " << key
1558  << " maps to multiple string key/CLID pairs: "
1559  << *str2 << "/" << clid2 << " and "
1560  << str << "/" << clid;
1561  }
1562 }

◆ reinitialize()

StatusCode SGImplSvc::reinitialize ( )
finaloverridevirtual

Service reinitialization.

Definition at line 336 of file SGImplSvc.cxx.

336  {
337  verbose() << "Reinitializing " << name() << endmsg ;
338  const bool FORCEREMOVE(true);
339  clearStore(FORCEREMOVE).ignore();
340  //not in v20r2p2! return Service::reinitialize();
341  return StatusCode::SUCCESS;
342 }

◆ releaseObject()

void SGImplSvc::releaseObject ( const CLID id,
const std::string &  key 
)
private

release object held by proxy, if any.

Gives up ownership (somebody else must take charge)

Definition at line 1589 of file SGImplSvc.cxx.

1589  {
1590  lock_t lock (m_mutex);
1591  DataProxy *pP(0);
1592  if (0 != (pP = proxy(id, key))) {
1593  // remove all entries from t2p map
1594  SG::DataProxy::CLIDCont_t clids = pP->transientID();
1595  SG::DataProxy::CLIDCont_t::const_iterator i(clids.begin()), e(clids.end());
1596  while (i != e) t2pRemove(SG::DataProxy_cast (pP, *i++));
1597  DataBucketBase *pDBB(dynamic_cast<DataBucketBase*>(pP->object()));
1598  //tell the bucket to let go of the data object
1599  if (0 != pDBB) pDBB->relinquish(); //somebody else better took ownership
1600  bool hard_reset = (m_numSlots > 1);
1601  pP->reset (hard_reset);
1602  }
1603 }

◆ remap_impl()

void SGImplSvc::remap_impl ( sgkey_t  source,
sgkey_t  target,
off_t  index_offset 
)

Declare a remapping.

source Key hash of the container being remapped.

target Key hash of the container being remapped to.

index_offset Amount by which the index should be adjusted between the two containers.

Definition at line 1634 of file SGImplSvc.cxx.

1637 {
1638  lock_t lock (m_remapMutex);
1640  payload.target = target;
1641  payload.index_offset = index_offset;
1642  m_remap_impl->m_remaps[source] = payload;
1643 }

◆ remove()

StatusCode SGImplSvc::remove ( const void *  pObject)

Remove pObject, will remove its proxy if not reset only.

Definition at line 1363 of file SGImplSvc.cxx.

1364 {
1365  lock_t lock (m_mutex);
1366  return removeProxy(proxy(pObject), pObject);
1367 }

◆ removeDataAndProxy()

StatusCode SGImplSvc::removeDataAndProxy ( const void *  pObject)

Remove pObject and its proxy no matter what.

Definition at line 1372 of file SGImplSvc.cxx.

1373 {
1374  lock_t lock (m_mutex);
1375  const bool FORCEREMOVE(true);
1376  return removeProxy(proxy(pObject), pObject, FORCEREMOVE);
1377 }

◆ removeProxy()

StatusCode SGImplSvc::removeProxy ( SG::DataProxy proxy,
const void *  pTrans,
bool  forceRemove = false 
)
private

remove proxy from store, unless it is reset only.


provide pTrans!=0 (must match proxy...) to save time

Parameters
forceRemoveremove the proxy no matter what

Definition at line 1281 of file SGImplSvc.cxx.

1283 {
1284  lock_t lock (m_mutex);
1285  // check if valid proxy
1286  if (0 == proxy) return StatusCode::FAILURE;
1287 
1288  if (0 == pTrans) {
1289  DataBucketBase* bucket = dynamic_cast<DataBucketBase*>(proxy->object());
1290  if (bucket) pTrans = bucket->object();
1291  }
1292 
1293  // remove all entries from t2p map
1294  // --- only if the proxy actually has an object!
1295  // otherwise, we can trigger I/O.
1296  // besides being useless here, we can get deadlocks if we
1297  // call into the I/O code while holding the SG lock.
1298  if (proxy->isValidObject()) {
1299  this->t2pRemove(pTrans);
1301  for (SG::DataProxy::CLIDCont_t::const_iterator i = clids.begin();
1302  i != clids.end();
1303  ++i)
1304  {
1305  void* ptr = SG::DataProxy_cast (proxy, *i);
1306  this->t2pRemove(ptr);
1307  }
1308  }
1309 
1310  // remove from store
1311  return m_pStore->removeProxy(proxy, forceRemove, true);
1312 }

◆ retrieve()

StatusCode SGImplSvc::retrieve ( CLID  clid,
SG::detail::IteratorBase cibegin,
SG::detail::IteratorBase ciend 
) const

Retrieve all objects of type T: returns an SG::ConstIterator range.

Definition at line 1893 of file SGImplSvc.cxx.

1896 {
1897  lock_t lock (m_mutex);
1900 
1901  if (!(proxyRange(clid,first,end)).isSuccess()) {
1902  std::string typnam;
1903  m_pCLIDSvc->getTypeNameOfID(clid, typnam).ignore();
1904  SG_MSG_DEBUG("retrieve(range): no object found "
1905  << " of type " << typnam
1906  << "(CLID " << clid << ')');
1907  }
1908 
1909  (ciend.setState(end, end, true)).ignore();
1910 
1911  if (!(cibegin.setState(first, end, true)).isSuccess()) {
1912  std::string typnam;
1913  m_pCLIDSvc->getTypeNameOfID(clid, typnam).ignore();
1914  SG_MSG_DEBUG("retrieve(range): Can't initialize iterator for object range "
1915  << " of type " << typnam
1916  << "(CLID " << clid << ')');
1917  return StatusCode::FAILURE;
1918  }
1919 
1920  return StatusCode::SUCCESS;
1921 }

◆ setAlias() [1/3]

StatusCode SGImplSvc::setAlias ( CLID  clid,
const std::string &  key,
const std::string &  aliasKey 
)

make an alias to a DataObject (provide data type and old key)

Definition at line 697 of file SGImplSvc.cxx.

699 {
700  lock_t lock (m_mutex);
701 
702  SG::DataProxy* dp(0);
703  dp = proxy(clid, key);
704  if (0 == dp) {
705  error() << "setAlias: problem setting alias "
706  << std::string(aKey) << '\n'
707  << "DataObject does not exist, record before setting alias."
708  << endmsg;
709  return StatusCode::FAILURE;
710  }
711 
712  StatusCode sc = addAlias(aKey, dp);
713  if (sc.isFailure()) {
714  error() << "setAlias: problem setting alias "
715  << (std::string)aKey << '\n'
716  << "DataObject does not exist, record before setting alias."
717  << endmsg;
718  return StatusCode::FAILURE;
719  }
720 
721  return StatusCode::SUCCESS;
722 }

◆ setAlias() [2/3]

StatusCode SGImplSvc::setAlias ( const void *  p2BAliased,
const std::string &  aliasKey 
)

make an alias to a DataObject (provide only valid pointer)

Definition at line 670 of file SGImplSvc.cxx.

671 {
672  lock_t lock (m_mutex);
673 
674  SG::DataProxy* dp(0);
675  dp = proxy(pObject);
676  if (0 == dp) {
677  error() << "setAlias: problem setting alias "
678  << aliasKey << '\n'
679  << "DataObject does not exist, record before setting alias."
680  << endmsg;
681  return StatusCode::FAILURE;
682  }
683 
684  StatusCode sc = addAlias(aliasKey, dp);
685  if (sc.isFailure()) {
686  error() << "setAlias: problem setting alias "
687  << aliasKey << '\n'
688  << "DataObject does not exist, record before setting alias."
689  << endmsg;
690  return StatusCode::FAILURE;
691  }
692 
693  return StatusCode::SUCCESS;
694 }

◆ setAlias() [3/3]

StatusCode SGImplSvc::setAlias ( SG::DataProxy proxy,
const std::string &  aliasKey 
)

make an alias to a DataObject (provide valid proxy)

Definition at line 724 of file SGImplSvc.cxx.

725 {
726  return addAlias( aliasKey, proxy );
727 }

◆ setConst()

StatusCode SGImplSvc::setConst ( const void *  pointer)

prevent downstream clients from modifying the pointed-at dobj

Definition at line 1343 of file SGImplSvc.cxx.

1344 {
1345  lock_t lock (m_mutex);
1346  // Check if DataProxy does not exist
1347  DataProxy * dp = proxy(pObject);
1348 
1349  if (0 == dp)
1350  {
1351  warning() << "setConst: NO Proxy for the dobj you want to set const"
1352  << endmsg;
1353  return StatusCode::FAILURE;
1354  }
1355 
1356  dp->setConst();
1357  return StatusCode::SUCCESS;
1358 }

◆ setProxyProviderSvc()

void SGImplSvc::setProxyProviderSvc ( IProxyProviderSvc pPPSvc)

associate ProxyProviderSvc to this store

◆ setSlotNumber()

void SGImplSvc::setSlotNumber ( int  slot,
int  numSlots 
)

Set the Hive slot number for this store.

Parameters
slotThe slot number. -1 means that this isn't a Hive store.
numSlotsThe total number of slots. Should be 1 for the non-Hive case.

Definition at line 965 of file SGImplSvc.cxx.

966 {
967  m_slotNumber = slot;
968  m_numSlots = numSlots;
969 
971  header->setArenaForSlot (slot, &m_arena);
972 }

◆ setStoreID()

void SGImplSvc::setStoreID ( StoreID::type  id)

set store ID. request forwarded to DataStore:

set store id in DataStore:

Definition at line 516 of file SGImplSvc.cxx.

517 {
518  lock_t lock (m_mutex);
519  store()->setStoreID(id);
520 }

◆ setupProxy()

DataProxy * SGImplSvc::setupProxy ( const CLID dataID,
const std::string &  gK,
DataObject *  pDObj,
bool  allowMods,
bool  resetOnly 
)
private

try to locate a proxy or create it if needed

Definition at line 474 of file SGImplSvc.cxx.

478  {
479  // locate the proxy
480  DataProxy* dp = m_pStore->proxy_exact(dataID, gK);
481 
482  if (0 != dp) { //proxy found
483  if (0 != dp->object())
484  {
485  // Case 0: duplicated proxy
486  warning() << " setupProxy:: error setting up proxy for key "
487  << gK << " and clid " << dataID
488  << "\n Pre-existing valid DataProxy @"<< dp
489  << " found in Store for key " << dp->object()->name()
490  << " with clid " << dp->object()->clID()
491  << endmsg;
492  recycle(pDObj); // commit this object to trash
493  dp = 0;
494  } else {
495  // Case 1: Proxy found... if not valid, update it:
496  dp->setObject(pDObj);
497  if (!allowMods) dp->setConst();
498  }
499  } else {
500  // Case 2: No Proxy found:
501  dp = new DataProxy(pDObj,
502  TransientAddress(dataID, gK),
503  !allowMods, resetOnly);
504  if (!(m_pStore->addToStore(dataID, dp).isSuccess())) {
505  warning() << " setupProxy:: could not addToStore proxy @" << dp
506  << endmsg;
507  recycle(pDObj); // commit this object to trash
508  delete dp;
509  dp = 0;
510  }
511  }
512  return dp;
513 }

◆ sourceID()

SG::SourceID SGImplSvc::sourceID ( const std::string &  key = "EventSelector") const
overridevirtual

Return the metadata source ID for the current event slot.

Parameters
keySG key of the DataHeader to query. Returns an empty string if no source has been set.

The default version always returns an empty string.

Returns an empty string if no source has been set.

The default version always returns an empty string.

Reimplemented from IProxyDict.

Definition at line 1875 of file SGImplSvc.cxx.

1876 {
1877  lock_t lock (m_mutex);
1879  if (dp) {
1880  const DataHeader* dh = SG::DataProxy_cast<DataHeader> (dp);
1881  if (dh) {
1882  return dh->begin()->getToken()->dbID().toString();
1883  }
1884  }
1885  return "";
1886 }

◆ start()

StatusCode SGImplSvc::start ( )
finaloverridevirtual

Service start.

Definition at line 201 of file SGImplSvc.cxx.

201  {
202 
203  verbose() << "Start " << name() << endmsg;
204  /*
205  // This will need regFcn clients to be updated first.
206  if ( 0 == m_pPPS || (m_pPPS->preLoadProxies(*m_pStore)).isFailure() ) {
207  debug() << " Failed to preLoad proxies"
208  << endmsg;
209  return StatusCode::FAILURE;
210  }
211  */
212 
213  return StatusCode::SUCCESS;
214 }

◆ stop()

StatusCode SGImplSvc::stop ( )
finaloverridevirtual

Service stop.

Definition at line 216 of file SGImplSvc.cxx.

216  {
217 
218  verbose() << "Stop " << name() << endmsg;
219  //HACK ALERT: ID event store objects refer to det store objects
220  //by setting an ad-hoc priority for event store(s) we make sure they are finalized and hence cleared first
221  // see e.g. https://savannah.cern.ch/bugs/index.php?99993
222  if (store()->storeID() == StoreID::EVENT_STORE) {
223  ISvcManager* pISM(dynamic_cast<ISvcManager*>(serviceLocator().get()));
224  if (!pISM)
225  return StatusCode::FAILURE;
226  pISM->setPriority(name(), pISM->getPriority(name())+1).ignore();
227  verbose() << "stop: setting service priority to " << pISM->getPriority(name())
228  << " so that event stores get finalized and cleared before other stores" <<endmsg;
229  }
230  return StatusCode::SUCCESS;
231 }

◆ store() [1/2]

DataStore * SGImplSvc::store ( )
private

Definition at line 612 of file SGImplSvc.cxx.

613 {
614  return m_pStore;
615 }

◆ store() [2/2]

const DataStore * SGImplSvc::store ( ) const
private

Definition at line 618 of file SGImplSvc.cxx.

619 {
620  return m_pStore;
621 }

◆ storeID()

StoreID::type SGImplSvc::storeID ( ) const

get store ID. request forwarded to DataStore:

get store id from DataStore:

Definition at line 522 of file SGImplSvc.cxx.

523 {
524  lock_t lock (m_mutex);
525  return store()->storeID();
526 }

◆ stringToKey()

SGImplSvc::sgkey_t SGImplSvc::stringToKey ( const std::string &  str,
CLID  clid 
)
finaloverridevirtual

Find the key for a string/CLID pair.

Parameters
strThe string to look up.
clidThe CLID associated with the string.
Returns
A key identifying the string. A given string will always return the same key. Will abort in case of a hash collision!

Implements IStringPool.

Definition at line 1500 of file SGImplSvc.cxx.

1501 {
1502  lock_t lock (m_stringPoolMutex);
1503  return m_stringpool.stringToKey (str, clid);
1504 }

◆ symLink() [1/2]

StatusCode SGImplSvc::symLink ( const CLID  id,
const std::string &  key,
const CLID  linkid 
)

make a soft link to the object pointed by id/key

Definition at line 638 of file SGImplSvc.cxx.

639 {
640  lock_t lock (m_mutex);
641  SG::DataProxy* dp(proxy(id, key, false));
642  // if symLink already exists, just return success
643  return isSymLinked(linkID,dp) ?
644  StatusCode::SUCCESS :
645  addSymLink(linkID,dp);
646 }

◆ symLink() [2/2]

StatusCode SGImplSvc::symLink ( const void *  p2BRegistered,
CLID  linkID 
)

make a soft link to the object T* already registered

Definition at line 627 of file SGImplSvc.cxx.

628 {
629  lock_t lock (m_mutex);
630  SG::DataProxy* dp(proxy(pObject));
631 
632  // if symLink already exists, just return success
633  return isSymLinked(linkID,dp) ?
634  StatusCode::SUCCESS :
635  addSymLink(linkID,dp);
636 }

◆ t2pRegister()

StatusCode SGImplSvc::t2pRegister ( const void *const  pTrans,
SG::DataProxy *const  pPers 
)
private

forwarded to DataStore

Definition at line 1315 of file SGImplSvc.cxx.

1316 {
1317  return m_pStore->t2pRegister(pTrans, pPers);
1318 }

◆ t2pRemove()

void SGImplSvc::t2pRemove ( const void *const  pTrans)
private

forwarded to DataStore

Definition at line 1322 of file SGImplSvc.cxx.

1323 {
1324  m_pStore->t2pRemove(pTrans);
1325 }

◆ transientContains()

bool SGImplSvc::transientContains ( const CLID  id,
const std::string &  key 
) const

Look up a transient data object in TDS only by CLID.

returns false if object not available in TDS

Definition at line 759 of file SGImplSvc.cxx.

760 {
761  try {
762  return (0 != transientProxy(id, key));
763  } catch(...) { return false; }
764 }

◆ transientProxy()

DataProxy * SGImplSvc::transientProxy ( const CLID id,
const std::string &  key 
) const

get proxy with given id and key.

Does not query ProxyProviderSvc.

Returns
0 to flag failure

Definition at line 1007 of file SGImplSvc.cxx.

1008 {
1009  lock_t lock (m_mutex);
1010  DataProxy* dp(m_pStore->proxy(id, key));
1011  return ( (0 != dp && dp->isValidObject()) ? dp : 0 );
1012 }

◆ transientSwap()

bool SGImplSvc::transientSwap ( const CLID id,
const std::string &  keyA,
const std::string &  keyB 
)

swap the content of 2 keys payload A indexed by keyA will now be accessed via keyB and vice versa Note that the swap is invalidated at event boundaries and/or when somebody clear the store.

Returns
false if swap failed

Definition at line 1031 of file SGImplSvc.cxx.

1033 {
1034  lock_t lock (m_mutex);
1035  const bool checkValid = true;
1036  DataProxy* a = proxy( id, keyA, checkValid );
1037  DataProxy* b = proxy( id, keyB, checkValid );
1038  if ( 0 == a || 0 == b ) { return false; }
1039  DataObject* objA = a->accessData();
1040  DataObject* objB = b->accessData();
1041 
1042  if ( 0 == objA || 0 == objB ) { return false; }
1043  // prevent 'accidental' release of DataObjects...
1044  const unsigned int refCntA = objA->addRef();
1045  const unsigned int refCntB = objB->addRef();
1046  // in case swap is being specialized for DataObjects
1047  using std::swap;
1048  swap( objA, objB );
1049  a->setObject( objA );
1050  b->setObject( objB );
1051  // and then restore old ref-count;
1052  return ( (refCntA-1) == objA->release() &&
1053  (refCntB-1) == objB->release() );
1054 }

◆ tryELRemap()

bool SGImplSvc::tryELRemap ( sgkey_t  sgkey_in,
size_t  index_in,
sgkey_t sgkey_out,
size_t &  index_out 
)
finaloverridevirtual

Test to see if the target of an ElementLink has moved.

Parameters
sgkey_inOriginal hashed key of the EL.
index_inOriginal index of the EL.
sgkey_out[out]New hashed key for the EL.
index_out[out]New index for the EL.
Returns
True if there is a remapping; false otherwise.

Reimplemented from IProxyDict.

Definition at line 1654 of file SGImplSvc.cxx.

1656 {
1657  lock_t lock (m_remapMutex);
1659  m_remap_impl->m_remaps.find (sgkey_in);
1660  if (i == m_remap_impl->m_remaps.end())
1661  return false;
1662  const SG::RemapImpl::remap_t& payload = i->second;
1663  sgkey_out = payload.target;
1664  index_out = index_in + payload.index_offset;
1665  return true;
1666 }

◆ typeCount()

int SGImplSvc::typeCount ( const CLID id) const

Return the number of instances of type T (input CLID)

Definition at line 742 of file SGImplSvc.cxx.

743 {
744  lock_t lock (m_mutex);
745  return m_pStore->typeCount(id);
746 }

◆ typeless_overwrite()

StatusCode SGImplSvc::typeless_overwrite ( const CLID id,
DataObject *  obj,
const std::string &  key,
const void *const  raw_ptr,
bool  allowMods,
bool  noHist = false,
const std::type_info *  tinfo = 0 
)
private

same as typeless_record, allows to overwrite an object in memory or on disk

Definition at line 1105 of file SGImplSvc.cxx.

1112 {
1113  lock_t lock (m_mutex);
1114  StatusCode sc(StatusCode::SUCCESS);
1115  SG::DataProxy* toRemove(proxy(clid, key, false));
1116  if (0 != toRemove) {
1117  toRemove->addRef();
1118  const bool FORCEREMOVE(true);
1119  sc =removeProxy(toRemove, (void*)0, FORCEREMOVE);
1120  }
1121  if (sc.isSuccess()) {
1122  const bool ALLOWOVERWRITE(true);
1123  const bool NORESET(false);
1124  if (record_impl( obj, key, raw_ptr, allowMods, NORESET, ALLOWOVERWRITE, tinfo) == nullptr)
1125  sc = StatusCode::FAILURE;
1126  else if ( m_ActivateHistory && noHist && store()->storeID() == StoreID::EVENT_STORE ) {
1127  sc = record_HistObj( obj->clID(), key, name(), allowMods, NORESET );
1128  }
1129  }
1130  //for detector store objects managed by IIOVSvc, replace the old proxy with the new one (#104311)
1131  if (toRemove && sc.isSuccess() && store()->storeID() == StoreID::DETECTOR_STORE) {
1133  }
1134  if (toRemove)
1135  toRemove->release();
1136  return sc;
1137 }

◆ typeless_record() [1/3]

StatusCode SGImplSvc::typeless_record ( DataObject *  obj,
const std::string &  key,
const void *const  raw_ptr,
bool  allowMods,
bool  resetOnly,
bool  noHist,
const std::type_info *  tinfo 
)
private

Definition at line 1067 of file SGImplSvc.cxx.

1071 {
1072  return typeless_record (obj, key, raw_ptr, allowMods, resetOnly, noHist,tinfo,
1073  nullptr, true);
1074 }

◆ typeless_record() [2/3]

StatusCode SGImplSvc::typeless_record ( DataObject *  obj,
const std::string &  key,
const void *const  raw_ptr,
bool  allowMods,
bool  resetOnly,
bool  noHist,
const std::type_info *  tinfo,
SG::DataProxy **  proxy_ret,
bool  noOverwrite 
)
private

Definition at line 1078 of file SGImplSvc.cxx.

1084 {
1085  lock_t lock (m_mutex);
1086  SG::DataProxy* proxy =
1087  record_impl( obj, key, raw_ptr, allowMods, resetOnly, !noOverwrite, tinfo);
1088  if ( proxy == nullptr )
1089  return StatusCode::FAILURE;
1090  if (proxy_ret)
1091  *proxy_ret = proxy;
1092 
1093  if ( !m_ActivateHistory || noHist ) {
1094  return StatusCode::SUCCESS;
1095  }
1096 
1097  if ( store()->storeID() != StoreID::EVENT_STORE ) {
1098  return StatusCode::SUCCESS;
1099  } else {
1100  return record_HistObj( obj->clID(), key, name(), allowMods, resetOnly );
1101  }
1102 }

◆ typeless_record() [3/3]

StatusCode SGImplSvc::typeless_record ( DataObject *  obj,
const std::string &  key,
const void *const  raw_ptr,
bool  allowMods,
bool  resetOnly = true,
bool  noHist = false 
)
private

type-less recording of an object with a key, allow possibility of specifying const-access and history record

Definition at line 1057 of file SGImplSvc.cxx.

1060 {
1061  return typeless_record (obj, key, raw_ptr, allowMods, resetOnly, noHist, 0,
1062  nullptr, true);
1063 }

◆ typeless_retrievePrivateCopy()

DataObject * SGImplSvc::typeless_retrievePrivateCopy ( const CLID  clid,
const std::string &  key 
)

Definition at line 1669 of file SGImplSvc.cxx.

1671 {
1672  lock_t lock (m_mutex);
1673  DataObject* obj = nullptr;
1674  SG::DataProxy* dp = proxy (clid, key);
1675  //we do not want anyone to mess up with our copy hence we release it immediately.
1676  if (dp && dp->isValid()) {
1677  obj = dp->object();
1678  obj->addRef();
1680  }
1681  return obj;
1682 }

◆ unboundHandle()

void SGImplSvc::unboundHandle ( IResetable handle)
finaloverridevirtual

Tell the store that a handle has been unbound from a proxy.

Parameters
handleThe handle that was unbound. The default implementation does nothing.

Reimplemented from IProxyDict.

Definition at line 1812 of file SGImplSvc.cxx.

1813 {
1814  std::vector<IResetable*>& v = m_newBoundHandles[std::this_thread::get_id()];
1816  std::find (v.begin(), v.end(), handle);
1817  if (it != v.end())
1818  v.erase (it);
1819 }

Friends And Related Function Documentation

◆ ActiveStoreSvc

friend class ActiveStoreSvc
friend

Definition at line 684 of file SGImplSvc.h.

◆ AthenaInternal::py_sg_clearProxyPayload

◆ AthenaInternal::recordObjectToStore

PyObject* AthenaInternal::recordObjectToStore ( StoreGateSvc ,
PyObject ,
PyObject ,
bool  ,
bool  ,
bool   
)
friend

◆ AthenaOutputStream

friend class AthenaOutputStream
friend

access proxyRange()

Definition at line 608 of file SGImplSvc.h.

◆ IOVDbSvc

friend class IOVDbSvc
friend

access clearProxyPayload

Definition at line 592 of file SGImplSvc.h.

◆ IOVSvc

friend class IOVSvc
friend

access store()

Definition at line 615 of file SGImplSvc.h.

◆ IOVSvcTool

friend class IOVSvcTool
friend

Definition at line 593 of file SGImplSvc.h.

◆ PerfMon::StorePayloadMon

friend class PerfMon::StorePayloadMon
friend

Definition at line 595 of file SGImplSvc.h.

◆ PileUpMergeSvc

friend class PileUpMergeSvc
friend

Definition at line 616 of file SGImplSvc.h.

◆ SG::VarHandleBase

friend class SG::VarHandleBase
friend

access typeless_record

Definition at line 619 of file SGImplSvc.h.

◆ SGDeleteAlg

friend class SGDeleteAlg
friend

Definition at line 594 of file SGImplSvc.h.

◆ StoreGateSvc

friend class StoreGateSvc
friend

Definition at line 617 of file SGImplSvc.h.

Member Data Documentation

◆ m_ActivateHistory

bool SGImplSvc::m_ActivateHistory
private

Activate the history service.

Definition at line 705 of file SGImplSvc.h.

◆ m_arena

SG::Arena SGImplSvc::m_arena
private

Allocation arena to associate with this store.

Definition at line 722 of file SGImplSvc.h.

◆ m_DumpArena

bool SGImplSvc::m_DumpArena
private

DumpArena Property flag : trigger m_arena->report() at clearStore.

Definition at line 706 of file SGImplSvc.h.

◆ m_DumpStore

bool SGImplSvc::m_DumpStore
private

Dump Property flag: triggers dump() at EndEvent.

Definition at line 704 of file SGImplSvc.h.

◆ m_folderNameList

StringArrayProperty SGImplSvc::m_folderNameList
private

FolderNameList Property.

Definition at line 709 of file SGImplSvc.h.

◆ m_mutex

mutex_t SGImplSvc::m_mutex
mutableprivate

Definition at line 738 of file SGImplSvc.h.

◆ m_newBoundHandles

std::map<std::thread::id, std::vector<IResetable*> > SGImplSvc::m_newBoundHandles
private

Keep track of proxies bound since the last call to commitNewDataObjects or clearStore.

Has to be done per-thread. We can't use thread_specific_ptr because we want to be able to clear the vectors for all threads in clearStore().

Definition at line 734 of file SGImplSvc.h.

◆ m_numSlots

int SGImplSvc::m_numSlots
private

The total number of slots. 1 if this isn't a Hive store.

Definition at line 728 of file SGImplSvc.h.

◆ m_pCLIDSvc

IClassIDSvc* SGImplSvc::m_pCLIDSvc
private

Definition at line 690 of file SGImplSvc.h.

◆ m_pDataLoader

IConversionSvc* SGImplSvc::m_pDataLoader
private

Definition at line 691 of file SGImplSvc.h.

◆ m_pHistorySvc

IHistorySvc* SGImplSvc::m_pHistorySvc
private

Definition at line 698 of file SGImplSvc.h.

◆ m_pIncSvc

ServiceHandle<IIncidentSvc> SGImplSvc::m_pIncSvc
private

property

Definition at line 703 of file SGImplSvc.h.

◆ m_pIOVSvc

IIOVSvc* SGImplSvc::m_pIOVSvc
private

Definition at line 713 of file SGImplSvc.h.

◆ m_pPPS

IProxyProviderSvc* SGImplSvc::m_pPPS
private

Definition at line 696 of file SGImplSvc.h.

◆ m_pPPSHandle

ServiceHandle<IProxyProviderSvc> SGImplSvc::m_pPPSHandle
private

Definition at line 693 of file SGImplSvc.h.

◆ m_pStore

SG::DataStore* SGImplSvc::m_pStore
private

Definition at line 700 of file SGImplSvc.h.

◆ m_remap_impl

SG::RemapImpl* SGImplSvc::m_remap_impl
private

Definition at line 719 of file SGImplSvc.h.

◆ m_remapMutex

mutex_t SGImplSvc::m_remapMutex
mutableprivate

Definition at line 739 of file SGImplSvc.h.

◆ m_slotNumber

int SGImplSvc::m_slotNumber
private

The Hive slot number for this store, or -1 if this isn't a Hive store.

Definition at line 725 of file SGImplSvc.h.

◆ m_storeLoaded

bool SGImplSvc::m_storeLoaded
private

FIXME hack needed by loadEventProxies.

Definition at line 715 of file SGImplSvc.h.

◆ m_stringpool

SG::StringPool SGImplSvc::m_stringpool
private

Definition at line 717 of file SGImplSvc.h.

◆ m_stringPoolMutex

mutex_t SGImplSvc::m_stringPoolMutex
mutableprivate

Definition at line 740 of file SGImplSvc.h.

◆ m_trash

std::list<DataObject*> SGImplSvc::m_trash
private

The Recycle Bin.

Definition at line 701 of file SGImplSvc.h.


The documentation for this class was generated from the following files:
grepfile.info
info
Definition: grepfile.py:38
xAOD::iterator
JetConstituentVector::iterator iterator
Definition: JetConstituentVector.cxx:68
SG::VersionedKey::isVersionedKey
static bool isVersionedKey(const char *)
quickly determine whether a string has the right format to be a VK
Definition: SGVersionedKey.cxx:18
SG::DataStore::typeCount
int typeCount(const CLID &id) const
Count number of object of a given type in store.
Definition: Control/SGTools/src/DataStore.cxx:405
common.sgkey
def sgkey(tool)
Definition: common.py:1028
TileDCSDataPlotter.dp
dp
Definition: TileDCSDataPlotter.py:840
SGImplSvc::addSymLink
StatusCode addSymLink(const CLID &linkid, SG::DataProxy *dp)
Definition: SGImplSvc.cxx:650
python.tests.PyTestsLib.finalize
def finalize(self)
_info( "content of StoreGate..." ) self.sg.dump()
Definition: PyTestsLib.py:53
python.SystemOfUnits.s
int s
Definition: SystemOfUnits.py:131
SG::DataStore::t2pRegister
StatusCode t2pRegister(const void *const pTrans, DataProxy *const pPers)
methods to query the T2PMap:
Definition: Control/SGTools/src/DataStore.cxx:613
python.trigbs_prescaleL1.ost
ost
Definition: trigbs_prescaleL1.py:104
header
Definition: hcg.cxx:526
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
SGImplSvc::clearStore
virtual StatusCode clearStore(bool forceRemove=false) override final
clear DataStore contents: called by the event loop mgrs
Definition: SGImplSvc.cxx:277
find
std::string find(const std::string &s)
return a remapped string
Definition: hcg.cxx:135
DataBucketBase
A non-templated base class for DataBucket, allows to access the transient object address as a void*.
Definition: DataBucketBase.h:24
SG::StringPool
Definition: StringPool.h:35
IProxyProviderSvc::loadProxies
virtual StatusCode loadProxies(IProxyRegistry &dataStore)=0
add new proxies to store every Event:
SGImplSvc::getIIOVSvc
IIOVSvc * getIIOVSvc()
get the IOVSvc "just in time" (breaks recursion at initialize)
Definition: SGImplSvc.cxx:234
DataBucketBase::object
virtual void * object()=0
initialize
void initialize()
Definition: run_EoverP.cxx:894
extractSporadic.c1
c1
Definition: extractSporadic.py:134
SGImplSvc::removeProxy
StatusCode removeProxy(SG::DataProxy *proxy, const void *pTrans, bool forceRemove=false)
remove proxy from store, unless it is reset only.
Definition: SGImplSvc.cxx:1281
PlotCalibFromCool.begin
begin
Definition: PlotCalibFromCool.py:94
skel.it
it
Definition: skel.GENtoEVGEN.py:423
SG::TransientAddress
Definition: TransientAddress.h:32
SG::DataStore::addToStore
virtual StatusCode addToStore(const CLID &id, DataProxy *proxy)
add proxy to store.
Definition: Control/SGTools/src/DataStore.cxx:139
SG::CurrentEventStore::setStore
static IProxyDict * setStore(IProxyDict *store)
Set the current store.
Definition: CurrentEventStore.cxx:36
SGImplSvc::m_newBoundHandles
std::map< std::thread::id, std::vector< IResetable * > > m_newBoundHandles
Keep track of proxies bound since the last call to commitNewDataObjects or clearStore.
Definition: SGImplSvc.h:734
IIOVSvc::regProxy
virtual StatusCode regProxy(SG::DataProxy *proxy, const std::string &key, const std::string &storeName="StoreGateSvc")=0
Subscribe method for DataProxy. key StoreGate key.
SGImplSvc::proxyRange
StatusCode proxyRange(const CLID &id, SG::ConstProxyIterator &beg, SG::ConstProxyIterator &end) const
return a range to all proxies of a given CLID
Definition: SGImplSvc.cxx:1336
CLIDRegistry::CLIDToTypeinfo
static const std::type_info * CLIDToTypeinfo(CLID clid)
Translate between CLID and type_info.
Definition: CLIDRegistry.cxx:136
SG::AuxVectorBase::setStore
void setStore(SG::IAuxStore *store)
Set the store associated with this object.
Definition: AuxVectorBase.cxx:96
SGImplSvc::m_stringPoolMutex
mutex_t m_stringPoolMutex
Definition: SGImplSvc.h:740
SGImplSvc::m_pIncSvc
ServiceHandle< IIncidentSvc > m_pIncSvc
property
Definition: SGImplSvc.h:703
SGImplSvc::emptyTrash
void emptyTrash()
throw away bad objects
Definition: SGImplSvc.cxx:1387
SG::asStorable
DataObject * asStorable(T *pObject)
Definition: StorableConversions.h:158
SG::DataStore::ConstStoreIterator
StoreMap::const_iterator ConstStoreIterator
Definition: Control/SGTools/SGTools/DataStore.h:80
SG::DataStore::clearStore
void clearStore(bool force, bool hard, MsgStream *pmlog)
If HARD is true, then the bound objects should also clear any data that depends on the identity of th...
Definition: Control/SGTools/src/DataStore.cxx:68
SG::DataProxy::isValid
bool isValid() const
called by destructor
PyPoolBrowser.dh
dh
Definition: PyPoolBrowser.py:102
IIOVSvc::replaceProxy
virtual StatusCode replaceProxy(SG::DataProxy *pOld, SG::DataProxy *pNew, const std::string &storeName="StoreGateSvc")=0
replace a registered proxy with a new version
SGImplSvc::proxies
virtual std::vector< const SG::DataProxy * > proxies() const override final
return the list of all current proxies in store
Definition: SGImplSvc.cxx:976
IHiveStoreMgr::interfaceID
static const InterfaceID & interfaceID()
Gaudi boilerplate.
Definition: IHiveStoreMgr.h:43
SG::RemapImpl
Definition: SGImplSvc.cxx:72
SG::BaseInfoBase::get_bases
const std::vector< CLID > & get_bases() const
Return the class IDs of all known bases of T (that have class IDs).
Definition: BaseInfo.cxx:304
SG::DataStore::proxy
virtual DataProxy * proxy(const TransientAddress *tAddr) const
return proxy for a given type/key pair if key is empty returns the default proxy (currently last regi...
Definition: Control/SGTools/src/DataStore.cxx:414
IProxyDict
A proxy dictionary.
Definition: AthenaKernel/AthenaKernel/IProxyDict.h:51
SG::DataStore::setStoreID
void setStoreID(StoreID::type id)
Definition: Control/SGTools/SGTools/DataStore.h:91
SG::detail::IteratorBase::setState
StatusCode setState(SG::ConstProxyIterator itr, SG::ConstProxyIterator itrEnd, bool isConst)
Reset state of the iterator.
Definition: SGIterator.cxx:94
python.FakeAthena.Service
def Service(name)
Definition: FakeAthena.py:38
SGImplSvc::m_ActivateHistory
bool m_ActivateHistory
Activate the history service.
Definition: SGImplSvc.h:705
SG::Arena::makeCurrent
ArenaBase * makeCurrent()
Make this Arena the current one for its ArenaHeader.
Definition: Arena.cxx:59
SG::DataProxy::CLIDCont_t
TransientAddress::TransientClidSet CLIDCont_t
Definition: DataProxy.h:53
SGImplSvc::m_storeLoaded
bool m_storeLoaded
FIXME hack needed by loadEventProxies.
Definition: SGImplSvc.h:715
SG::ArenaBase::report
void report(std::ostream &os) const
Generate a report of the memory in use by this Arena.
Definition: ArenaBase.cxx:76
AthenaPoolTestRead.sc
sc
Definition: AthenaPoolTestRead.py:27
SGImplSvc::m_slotNumber
int m_slotNumber
The Hive slot number for this store, or -1 if this isn't a Hive store.
Definition: SGImplSvc.h:725
SG::StringPool::clear
void clear()
Empty the pool.
Definition: StringPool.cxx:350
mergePhysValFiles.end
end
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:93
SG::RemapImpl::m_remaps
remap_map_t m_remaps
Definition: SGImplSvc.cxx:80
SGImplSvc::storeID
StoreID::type storeID() const
get store ID. request forwarded to DataStore:
Definition: SGImplSvc.cxx:522
SG::DataStore::proxy_exact
SG::DataProxy * proxy_exact(sgkey_t sgkey) const
get proxy with given key.
Definition: Control/SGTools/src/DataStore.cxx:524
DiTauMassTools::ignore
void ignore(T &&)
Definition: PhysicsAnalysis/TauID/DiTauMassTools/DiTauMassTools/HelperFunctions.h:54
SGImplSvc::m_pStore
SG::DataStore * m_pStore
Definition: SGImplSvc.h:700
IResetable
a resetable object (e.g. a SG DataHandle)
Definition: IResetable.h:15
python.UpdateManyBadChannelIOVs.toRemove
tuple toRemove
Definition: UpdateManyBadChannelIOVs.py:87
SGImplSvc::m_DumpStore
bool m_DumpStore
Dump Property flag: triggers dump() at EndEvent.
Definition: SGImplSvc.h:704
StdJOSetup.msgSvc
msgSvc
Provide convenience handles for various services.
Definition: StdJOSetup.py:36
SGImplSvc::clids
std::vector< CLID > clids() const
Return all CLIDs in the store.
Definition: SGImplSvc.cxx:986
DataHeader
This class provides the layout for summary information stored for data written to POOL.
Definition: DataHeader.h:124
lumiFormat.i
int i
Definition: lumiFormat.py:92
SG::ArenaHeader
Proxy for a group of Arenas.
Definition: ArenaHeader.h:54
SG::AuxElement::setStore
void setStore(const SG::IConstAuxStore *store)
Set the store associated with this object.
Definition: AuxElement.cxx:221
SGImplSvc::bindHandleToProxy
bool bindHandleToProxy(const CLID &id, const std::string &key, IResetable *ir, SG::DataProxy *&dp)
name says it all
Definition: SGImplSvc.cxx:1398
ret
T ret(T t)
Definition: rootspy.cxx:260
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
SG::ArenaBase::reset
void reset()
Reset all contained allocators.
Definition: ArenaBase.cxx:44
SGImplSvc::m_arena
SG::Arena m_arena
Allocation arena to associate with this store.
Definition: SGImplSvc.h:722
SG::DataProxy::alias
AliasCont_t alias() const
access set of proxy aliases Returns a COPY of the alias set.
SG::VersionedKey
a StoreGateSvc key with a version number. Notice that StoreGate does not order multiple instances of ...
Definition: SGVersionedKey.h:31
SGImplSvc::m_stringpool
SG::StringPool m_stringpool
Definition: SGImplSvc.h:717
SGImplSvc::m_pHistorySvc
IHistorySvc * m_pHistorySvc
Definition: SGImplSvc.h:698
ClassID_traits
Default, invalid implementation of ClassID_traits.
Definition: Control/AthenaKernel/AthenaKernel/ClassID_traits.h:40
SG::DataStore::addSymLink
StatusCode addSymLink(const CLID &linkid, DataProxy *proxy)
add symlink to store:
Definition: Control/SGTools/src/DataStore.cxx:330
SGImplSvc::clearProxyPayload
void clearProxyPayload(SG::DataProxy *)
use to reset a proxy (clearing the data object it contains) Unlike DataProxy::reset this method corre...
Definition: SGImplSvc.cxx:1606
SGImplSvc::setupProxy
SG::DataProxy * setupProxy(const CLID &dataID, const std::string &gK, DataObject *pDObj, bool allowMods, bool resetOnly)
try to locate a proxy or create it if needed
Definition: SGImplSvc.cxx:474
SG::BaseInfoBase::get_copy_conversions
std::vector< CLID > get_copy_conversions() const
Return known copy conversions.
Definition: BaseInfo.cxx:455
SGImplSvc
The Athena Transient Store API.
Definition: SGImplSvc.h:116
CHECK
#define CHECK(...)
Evaluate an expression and check for errors.
Definition: Control/AthenaKernel/AthenaKernel/errorcheck.h:422
SG::StringPool::keyToString
const std::string * keyToString(sgkey_t key) const
Find the string corresponding to a given key.
Definition: StringPool.cxx:286
Handler::svc
AthROOTErrorHandlerSvc * svc
Definition: AthROOTErrorHandlerSvc.cxx:10
SG::ArenaBase::erase
void erase()
Erase all contained allocators.
Definition: ArenaBase.cxx:60
DeMoUpdate.tmp
string tmp
Definition: DeMoUpdate.py:1167
SGImplSvc::record_impl
SG::DataProxy * record_impl(DataObject *obj, const std::string &key, const void *const raw_ptr, bool allowMods, bool resetOnly, bool allowOverwrite, const std::type_info *tinfo)
real recording of an object with a key, allow possibility of specifying const-access
Definition: SGImplSvc.cxx:1140
SG::AuxVectorData::hasStore
bool hasStore() const
Return true if this object has an associated store.
WriteCalibToCool.swap
swap
Definition: WriteCalibToCool.py:94
IProxyProviderSvc::preLoadProxies
virtual StatusCode preLoadProxies(IProxyRegistry &dataStore)=0
add proxies to the store before Begin Event:
CLID
uint32_t CLID
The Class ID type.
Definition: Event/xAOD/xAODCore/xAODCore/ClassID_traits.h:47
fcn
void fcn(int &, double *, double &result, double par[], int)
this is where we write out chi2
Definition: Chi2LJets.cxx:183
SG::DataProxy::clID
CLID clID() const
Retrieve clid.
StoreID::DETECTOR_STORE
@ DETECTOR_STORE
Definition: StoreID.h:27
SGImplSvc::msg_update_handler
void msg_update_handler(Gaudi::Details::PropertyBase &outputLevel)
callback for output level property
Definition: SGImplSvc.cxx:1328
SG::DataProxy_cast
DATA * DataProxy_cast(DataProxy *proxy)
cast the proxy into the concrete data object it proxies
IProxyProviderSvc::retrieveProxy
virtual SG::DataProxy * retrieveProxy(const CLID &id, const std::string &key, IProxyRegistry &dataStore)=0
Use a provider to create a proxy for ID/KEY.
SGImplSvc::recordAddress
StatusCode recordAddress(const std::string &skey, IOpaqueAddress *pAddress, bool clearAddressFlag=true)
Create a proxy object using an IOpaqueAddress and a transient key.
Definition: SGImplSvc.cxx:383
SG::DataStore::storeID
virtual StoreID::type storeID() const
Definition: Control/SGTools/SGTools/DataStore.h:92
SGImplSvc::dump
std::string dump() const
dump objects in store.
Definition: SGImplSvc.cxx:569
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:192
SGImplSvc::record_HistObj
StatusCode record_HistObj(const CLID &id, const std::string &key, const std::string &store, bool allowMods, bool resetOnly=true)
Definition: SGImplSvc.cxx:1464
debug
const bool debug
Definition: MakeUncertaintyPlots.cxx:53
ActsTrk::to_string
std::string to_string(const DetectorType &type)
Definition: GeometryDefs.h:34
plotBeamSpotMon.b
b
Definition: plotBeamSpotMon.py:77
compileRPVLLRates.c2
c2
Definition: compileRPVLLRates.py:361
SG::BaseInfoBase::find
static const BaseInfoBase * find(CLID clid)
Find the BaseInfoBase instance for clid.
Definition: BaseInfo.cxx:569
SGImplSvc::recycle
void recycle(DataObject *pBadDObj)
put a bad (unrecordable) dobj away
Definition: SGImplSvc.cxx:1380
SGImplSvc::m_DumpArena
bool m_DumpArena
DumpArena Property flag : trigger m_arena->report() at clearStore.
Definition: SGImplSvc.h:706
SG::DataStore::keys
void keys(const CLID &id, std::vector< std::string > &vkeys, bool includeAlias, bool onlyValid)
Definition: Control/SGTools/src/DataStore.cxx:118
SGImplSvc::clid
CLID clid(const std::string &key) const
Retrieve the main CLID of the object recorded in StoreGate with the given "key" WARNING: slow!
Definition: SGImplSvc.cxx:1685
SGImplSvc::typeless_record
StatusCode typeless_record(DataObject *obj, const std::string &key, const void *const raw_ptr, bool allowMods, bool resetOnly=true, bool noHist=false)
type-less recording of an object with a key, allow possibility of specifying const-access and history...
Definition: SGImplSvc.cxx:1057
IHiveStoreMgr
the interface through which HiveWB control StoreGate instances
Definition: IHiveStoreMgr.h:26
SG::DataProxy::name
virtual const name_type & name() const override final
Retrieve data object key == string.
SG::DataStore::locatePersistent
DataProxy * locatePersistent(const void *const pTransient) const
locate the persistent (proxy) for a given T* (void*):
Definition: Control/SGTools/src/DataStore.cxx:606
SGImplSvc::interfaceID
static const InterfaceID & interfaceID()
Should rather be in ISGImplSvc.h if we had one.
Definition: SGImplSvc.cxx:345
SGImplSvc::m_numSlots
int m_numSlots
The total number of slots. 1 if this isn't a Hive store.
Definition: SGImplSvc.h:728
PixelModuleFeMask_create_db.payload
string payload
Definition: PixelModuleFeMask_create_db.py:69
SGImplSvc::addAlias
StatusCode addAlias(const std::string &aliasKey, SG::DataProxy *dp)
Definition: SGImplSvc.cxx:730
REPORT_MESSAGE
#define REPORT_MESSAGE(LVL)
Report a message.
Definition: Control/AthenaKernel/AthenaKernel/errorcheck.h:365
SGImplSvc::handle
virtual void handle(const Incident &) override final
triggered by Incident service
Definition: SGImplSvc.cxx:244
SGImplSvc::m_pCLIDSvc
IClassIDSvc * m_pCLIDSvc
Definition: SGImplSvc.h:690
python.TrigPSCPythonDbSetup.outputLevel
outputLevel
Definition: TrigPSCPythonDbSetup.py:30
SG::IAuxStore
Interface for non-const operations on an auxiliary store.
Definition: IAuxStore.h:48
SG::AuxElement::hasStore
bool hasStore() const
Return true if this object has an associated store.
Definition: AuxElement.cxx:355
ir
int ir
counter of the current depth
Definition: fastadd.cxx:49
python.PyAthena.v
v
Definition: PyAthena.py:157
SG::DataProxy::isValidObject
bool isValidObject() const
is the object valid?
SG::ArenaHeader::defaultHeader
static ArenaHeader * defaultHeader()
Return the global default Header instance.
Definition: ArenaHeader.cxx:164
SGImplSvc::transientProxy
SG::DataProxy * transientProxy(const CLID &id, const std::string &key) const
get proxy with given id and key.
Definition: SGImplSvc.cxx:1007
DiTauMassTools::MaxHistStrategyV2::e
e
Definition: PhysicsAnalysis/TauID/DiTauMassTools/DiTauMassTools/HelperFunctions.h:26
a
TList * a
Definition: liststreamerinfos.cxx:10
InDetDD::other
@ other
Definition: InDetDD_Defs.h:16
SGImplSvc::m_pDataLoader
IConversionSvc * m_pDataLoader
Definition: SGImplSvc.h:691
h
SG::DataProxy::transientID
bool transientID(CLID id) const
return the list of transient IDs (primary or symLinked):
SGImplSvc::m_trash
std::list< DataObject * > m_trash
The Recycle Bin.
Definition: SGImplSvc.h:701
SG::DataStore
Hold DataProxy instances associated with a store.
Definition: Control/SGTools/SGTools/DataStore.h:73
SG::DataStore::proxies
const std::vector< DataProxy * > & proxies() const
All proxies managed by this store.
Definition: Control/SGTools/src/DataStore.cxx:627
SG::DataStore::addAlias
StatusCode addAlias(const std::string &aliasKey, DataProxy *proxy)
add alias to store
Definition: Control/SGTools/src/DataStore.cxx:377
StoreID::findStoreID
static StoreID::type findStoreID(const std::string &storeName)
Definition: StoreID.cxx:21
python.TriggerHandler.verbose
verbose
Definition: TriggerHandler.py:297
DeMoScan.first
bool first
Definition: DeMoScan.py:534
DEBUG
#define DEBUG
Definition: page_access.h:11
SG::BaseInfoBase
The non-template portion of the BaseInfo implementation.
Definition: Control/AthenaKernel/AthenaKernel/BaseInfo.h:451
SG::DataStore::t2pRemove
void t2pRemove(const void *const pTrans)
Definition: Control/SGTools/SGTools/DataStore.h:253
SGImplSvc::store
SG::DataStore * store()
Definition: SGImplSvc.cxx:612
get
T * get(TKey *tobj)
get a TObject* from a TKey* (why can't a TObject be a TKey?)
Definition: hcg.cxx:127
SGImplSvc::m_pPPS
IProxyProviderSvc * m_pPPS
Definition: SGImplSvc.h:696
SG::DataStore::pRange
StatusCode pRange(const CLID &id, SG::ConstProxyIterator &f, SG::ConstProxyIterator &e) const
Return an iterator over proxy for a given CLID:
Definition: Control/SGTools/src/DataStore.cxx:574
SGImplSvc::lock_t
std::lock_guard< mutex_t > lock_t
Definition: SGImplSvc.h:737
declareProperty
#define declareProperty(n, p, h)
Definition: BaseFakeBkgTool.cxx:15
SG::DataStore::removeProxy
StatusCode removeProxy(DataProxy *proxy, bool forceRemove, bool hard)
remove proxy from store, unless proxy is reset only.
Definition: Control/SGTools/src/DataStore.cxx:196
SG::StringPool::merge
bool merge(const StringPool &other)
Merge another pool into this one.
Definition: StringPool.cxx:363
str
Definition: BTagTrackIpAccessor.cxx:11
ATLAS_THREAD_SAFE
#define ATLAS_THREAD_SAFE
Definition: checker_macros.h:211
StoreID::EVENT_STORE
@ EVENT_STORE
Definition: StoreID.h:26
COOLRates.target
target
Definition: COOLRates.py:1106
SGImplSvc::createKey
std::string createKey(const CLID &dataID)
creates a key internally if none specified by client
Definition: SGImplSvc.cxx:268
SG::StringPool::stringToKey
sgkey_t stringToKey(const std::string &str, sgaux_t aux=0)
Find the key for a string.
Definition: StringPool.cxx:248
SG::RemapImpl::remap_t
Definition: SGImplSvc.cxx:75
get_generator_info.error
error
Definition: get_generator_info.py:40
SG::IConstAuxStore
Interface for const operations on an auxiliary store.
Definition: IConstAuxStore.h:64
SGImplSvc::m_mutex
mutex_t m_mutex
Definition: SGImplSvc.h:738
SGImplSvc::t2pRemove
void t2pRemove(const void *const pTrans)
forwarded to DataStore
Definition: SGImplSvc.cxx:1322
python.PyAthena.obj
obj
Definition: PyAthena.py:135
SGImplSvc::m_pPPSHandle
ServiceHandle< IProxyProviderSvc > m_pPPSHandle
Definition: SGImplSvc.h:693
SG::DataProxy
Definition: DataProxy.h:44
SGImplSvc::regFcn
StatusCode regFcn(const CallBackID &c1, const CallBackID &c2, const IOVSvcCallBackFcn &fcn, bool trigger=false)
register a callback function(2) with an already registered function(1)
Definition: SGImplSvc.cxx:546
IIOVSvc::regFcn
virtual StatusCode regFcn(SG::DataProxy *dp, const CallBackID &c, const IOVSvcCallBackFcn &fcn, bool trigger=false)=0
register callback function
SGImplSvc::m_pIOVSvc
IIOVSvc * m_pIOVSvc
Definition: SGImplSvc.h:713
SGImplSvc::proxy
virtual SG::DataProxy * proxy(const void *const pTransient) const override final
get proxy for a given data object address in memory
Definition: SGImplSvc.cxx:768
SGImplSvc::isSymLinked
bool isSymLinked(const CLID &linkID, SG::DataProxy *dp)
Definition: SGImplSvc.cxx:539
Amg::distance
float distance(const Amg::Vector3D &p1, const Amg::Vector3D &p2)
calculates the distance between two point in 3D space
Definition: GeoPrimitivesHelpers.h:54
SG::DataStore::tRange
StatusCode tRange(ConstStoreIterator &f, ConstStoreIterator &e) const
Return an iterator over the StoreMap:
Definition: Control/SGTools/src/DataStore.cxx:596
SGImplSvc::t2pRegister
StatusCode t2pRegister(const void *const pTrans, SG::DataProxy *const pPers)
forwarded to DataStore
Definition: SGImplSvc.cxx:1315
SG::DataStore::proxy_exact_unlocked
SG::DataProxy * proxy_exact_unlocked(sgkey_t sgkey, std::recursive_mutex &mutex) const
Like proxy_exact, but intended to be called without holding the store lock.
Definition: Control/SGTools/src/DataStore.cxx:543
python.compressB64.c
def c
Definition: compressB64.py:93
SG::ArenaBase::name
const std::string & name() const
Return this Arena's name.
Definition: ArenaBase.cxx:114
SG::ConstProxyIterator
ProxyMap::const_iterator ConstProxyIterator
Definition: ProxyMap.h:28
SG::StringPool::registerKey
bool registerKey(sgkey_t key, const std::string &str, sgaux_t aux=0)
Remember an additional mapping from key to string.
Definition: StringPool.cxx:319
SGImplSvc::addAutoSymLinks
void addAutoSymLinks(const std::string &key, CLID clid, SG::DataProxy *dp, const std::type_info *tinfo, bool warn_nobib=true)
Add automatically-made symlinks for DP.
Definition: SGImplSvc.cxx:1719
SGImplSvc::m_remap_impl
SG::RemapImpl * m_remap_impl
Definition: SGImplSvc.h:719
PhysDESDM_Quirks.trigger
trigger
Definition: PhysDESDM_Quirks.py:27
SGImplSvc::m_remapMutex
mutex_t m_remapMutex
Definition: SGImplSvc.h:739
mapkey::key
key
Definition: TElectronEfficiencyCorrectionTool.cxx:37