ATLAS Offline Software
Loading...
Searching...
No Matches
IIOVSvc.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef ATHENAKERNEL_IIOVSVC_H
6#define ATHENAKERNEL_IIOVSVC_H
7
8#include "GaudiKernel/IService.h"
9#include "GaudiKernel/StatusCode.h"
10#include "GaudiKernel/ClassID.h"
11#include "GaudiKernel/IOpaqueAddress.h"
12
13#include <string>
14#include <vector>
15#include <set>
16#include <memory>
17
19
20class IOVRange;
21class IOVTime;
22class IIOVSvcTool;
23class CallBackID;
24class IOpaqueAddress;
25class CondContBase;
26class DataObjID;
27class EventIDBase;
28
29namespace SG {
30 class DataProxy;
31 class TransientAddress;
32}
33
40
41class IIOVSvc : virtual public IService {
42
43public:
45
46 virtual StatusCode createIOVTool( const std::string& storeName ) = 0;
47 virtual std::vector<std::string> getStoreNames() const = 0;
48
50
51
59 virtual StatusCode regFcn(SG::DataProxy *dp, const CallBackID& c,
60 const IOVSvcCallBackFcn& fcn,
61 bool trigger=false) = 0;
62
70 virtual StatusCode regFcn(const CallBackID& c1, const CallBackID& c2,
71 const IOVSvcCallBackFcn& fcn2,
72 bool trigger=false ) = 0;
73
81 virtual StatusCode regFcn(const std::string &toolName, const CallBackID& c2,
82 const IOVSvcCallBackFcn& fcn2,
83 bool trigger=false) = 0;
84
86 virtual StatusCode regProxy( SG::DataProxy *proxy,
87 const std::string& key,
88 const std::string& storeName="StoreGateSvc") = 0;
90 virtual StatusCode replaceProxy( SG::DataProxy *pOld,
91 SG::DataProxy *pNew,
92 const std::string& storeName="StoreGateSvc") = 0;
93
95 virtual StatusCode regProxy( const CLID& clid, const std::string& key,
96 const std::string& storeName="StoreGateSvc" ) = 0;
98
99 virtual StatusCode deregProxy( SG::DataProxy *proxy ) = 0;
100 virtual StatusCode deregProxy( const CLID& clid, const std::string& key ) = 0;
101
102
103
105
106 virtual StatusCode setRange(const CLID& clid, const std::string& key,
107 IOVRange&) = 0;
108 virtual StatusCode setRange(const CLID& clid, const std::string& key,
109 IOVRange&,
110 const std::string& storeName) = 0;
111
112 virtual StatusCode getRange(const CLID& clid, const std::string& key,
113 IOVRange& iov ) const = 0;
114
116 virtual StatusCode getRangeFromDB(const CLID& clid, const std::string& key,
117 IOVRange& range, std::string &tag,
118 std::unique_ptr<IOpaqueAddress>& ioa,
119 const EventIDBase& now) const =0;
120
122 virtual StatusCode getRangeFromDB(const CLID& clid, const std::string& key,
123 const IOVTime& time,
124 IOVRange& range, std::string &tag,
125 std::unique_ptr<IOpaqueAddress>& ioa) const=0;
126
128 virtual StatusCode setRangeInDB(const CLID& clid, const std::string& key,
129 const IOVRange& range,
130 const std::string &tag) = 0;
132
133
135 virtual StatusCode dropObjectFromDB(const CLID& clid, const std::string& key,
136 const std::string& storeName) = 0;
137
139 virtual StatusCode preLoadTAD( const SG::TransientAddress *,
140 const std::string& storeName="StoreGateSvc" ) = 0;
141
142 // supply a list of TADs whose data will be preloaded via a 'partial preload' flag
143 virtual StatusCode preLoadDataTAD( const SG::TransientAddress *,
144 const std::string& storeName="StoreGateSvc" ) = 0;
145
147 virtual StatusCode getTriggeredTools(const std::string& key,
148 std::set<std::string>& tools,
149 const std::string& storeName="StoreGateSvc") = 0;
150
152 virtual void resetAllProxies() = 0;
153
154 virtual void ignoreProxy(const CLID& clid, const std::string& key,
155 const std::string& storeName="StoreGateSvc") = 0;
156
157 virtual StatusCode createCondObj(CondContBase*, const DataObjID&,
158 const EventIDBase&) = 0;
159
160};
161
162#endif
uint32_t CLID
The Class ID type.
defines and typedefs for IOVSvc
boost::function< StatusCode(IOVSVC_CALLBACK_ARGS) > IOVSvcCallBackFcn
the type of an IOVSvc call back: it wraps both the method and the object the method is called on
Definition IOVSvcDefs.h:58
Base class for all conditions containers.
Definition CondCont.h:140
Abstract interface for IOVSvc.
Definition IIOVSvc.h:41
virtual StatusCode getRange(const CLID &clid, const std::string &key, IOVRange &iov) const =0
virtual std::vector< std::string > getStoreNames() const =0
virtual StatusCode createIOVTool(const std::string &storeName)=0
virtual StatusCode createCondObj(CondContBase *, const DataObjID &, const EventIDBase &)=0
virtual StatusCode preLoadDataTAD(const SG::TransientAddress *, const std::string &storeName="StoreGateSvc")=0
virtual StatusCode getRangeFromDB(const CLID &clid, const std::string &key, const IOVTime &time, IOVRange &range, std::string &tag, std::unique_ptr< IOpaqueAddress > &ioa) const =0
Get IOVRange from db for a particular event.
virtual StatusCode getRangeFromDB(const CLID &clid, const std::string &key, IOVRange &range, std::string &tag, std::unique_ptr< IOpaqueAddress > &ioa, const EventIDBase &now) const =0
Get IOVRange from db for current event.
virtual StatusCode setRange(const CLID &clid, const std::string &key, IOVRange &, const std::string &storeName)=0
virtual StatusCode setRangeInDB(const CLID &clid, const std::string &key, const IOVRange &range, const std::string &tag)=0
Set a particular IOVRange in db (and memory)
virtual StatusCode dropObjectFromDB(const CLID &clid, const std::string &key, const std::string &storeName)=0
Drop the associated object from the db and trigger reload.
virtual StatusCode replaceProxy(SG::DataProxy *pOld, SG::DataProxy *pNew, const std::string &storeName="StoreGateSvc")=0
replace a registered proxy with a new version
virtual StatusCode setRange(const CLID &clid, const std::string &key, IOVRange &)=0
virtual StatusCode regFcn(const CallBackID &c1, const CallBackID &c2, const IOVSvcCallBackFcn &fcn2, bool trigger=false)=0
register callback function
virtual StatusCode preLoadTAD(const SG::TransientAddress *, const std::string &storeName="StoreGateSvc")=0
pre-load transient Addresses
virtual void resetAllProxies()=0
reset all proxies known to IOVSvc
virtual StatusCode regFcn(SG::DataProxy *dp, const CallBackID &c, const IOVSvcCallBackFcn &fcn, bool trigger=false)=0
register callback function
virtual StatusCode regFcn(const std::string &toolName, const CallBackID &c2, const IOVSvcCallBackFcn &fcn2, bool trigger=false)=0
register callback function
virtual void ignoreProxy(const CLID &clid, const std::string &key, const std::string &storeName="StoreGateSvc")=0
virtual StatusCode regProxy(SG::DataProxy *proxy, const std::string &key, const std::string &storeName="StoreGateSvc")=0
Subscribe method for DataProxy. key StoreGate key.
virtual StatusCode deregProxy(SG::DataProxy *proxy)=0
virtual StatusCode deregProxy(const CLID &clid, const std::string &key)=0
DeclareInterfaceID(IIOVSvc, 1, 0)
virtual StatusCode getTriggeredTools(const std::string &key, std::set< std::string > &tools, const std::string &storeName="StoreGateSvc")=0
get the names of the tools that have been triggered
virtual StatusCode regProxy(const CLID &clid, const std::string &key, const std::string &storeName="StoreGateSvc")=0
Another way to subscribe.
Validity Range object.
Definition IOVRange.h:30
Basic time unit for IOVSvc.
Definition IOVTime.h:33
Forward declaration.