ATLAS Offline Software
IIOVSvc.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 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 
20 class IOVRange;
21 class IOVTime;
22 class IIOVSvcTool;
23 class CallBackID;
24 class IOpaqueAddress;
25 class CondContBase;
26 class DataObjID;
27 class EventIDBase;
28 
29 namespace SG {
30  class DataProxy;
31  class TransientAddress;
32 }
33 
41 class IIOVSvc : virtual public IService {
42 
43 public:
45 
46  virtual StatusCode createIOVTool( const std::string& storeName ) = 0;
47  virtual std::vector<std::string> getStoreNames() const = 0;
48 
50 
51 
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 
87  const std::string& key,
88  const std::string& storeName="StoreGateSvc") = 0;
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 
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) const =0;
119 
121  virtual StatusCode getRangeFromDB(const CLID& clid, const std::string& key,
122  const IOVTime& time,
123  IOVRange& range, std::string &tag,
124  std::unique_ptr<IOpaqueAddress>& ioa) const=0;
125 
127  virtual StatusCode setRangeInDB(const CLID& clid, const std::string& key,
128  const IOVRange& range,
129  const std::string &tag) = 0;
131 
132 
134  virtual StatusCode dropObjectFromDB(const CLID& clid, const std::string& key,
135  const std::string& storeName) = 0;
136 
139  const std::string& storeName="StoreGateSvc" ) = 0;
140 
141  // supply a list of TADs whose data will be preloaded via a 'partial preload' flag
143  const std::string& storeName="StoreGateSvc" ) = 0;
144 
146  virtual StatusCode getTriggeredTools(const std::string& key,
147  std::set<std::string>& tools,
148  const std::string& storeName="StoreGateSvc") = 0;
149 
151  virtual void resetAllProxies() = 0;
152 
153  virtual void ignoreProxy(const CLID& clid, const std::string& key,
154  const std::string& storeName="StoreGateSvc") = 0;
155 
156  virtual StatusCode createCondObj(CondContBase*, const DataObjID&,
157  const EventIDBase&) = 0;
158 
159 };
160 
161 #endif
IIOVSvc::createIOVTool
virtual StatusCode createIOVTool(const std::string &storeName)=0
CallBackID
Definition: CallBackID.h:24
TileDCSDataPlotter.dp
dp
Definition: TileDCSDataPlotter.py:840
dqt_zlumi_alleff_HIST.iov
iov
Definition: dqt_zlumi_alleff_HIST.py:119
IOVRange
Validity Range object. Holds two IOVTimes (start and stop)
Definition: IOVRange.h:30
StateLessPT_NewConfig.proxy
proxy
Definition: StateLessPT_NewConfig.py:392
SG
Forward declaration.
Definition: CaloCellPacker_400_500.h:32
IIOVSvc::deregProxy
virtual StatusCode deregProxy(SG::DataProxy *proxy)=0
extractSporadic.c1
c1
Definition: extractSporadic.py:134
IIOVSvc::regFcn
virtual StatusCode regFcn(const std::string &toolName, const CallBackID &c2, const IOVSvcCallBackFcn &fcn2, bool trigger=false)=0
register callback function
SG::TransientAddress
Definition: TransientAddress.h:32
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.
IIOVSvc::deregProxy
virtual StatusCode deregProxy(const CLID &clid, const std::string &key)=0
IIOVSvc::regProxy
virtual StatusCode regProxy(const CLID &clid, const std::string &key, const std::string &storeName="StoreGateSvc")=0
Another way to subscribe.
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
IIOVSvc::getRangeFromDB
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.
IIOVSvc::createCondObj
virtual StatusCode createCondObj(CondContBase *, const DataObjID &, const EventIDBase &)=0
IIOVSvc::setRange
virtual StatusCode setRange(const CLID &clid, const std::string &key, IOVRange &)=0
IIOVSvcTool
Definition: IIOVSvcTool.h:27
IIOVSvc::DeclareInterfaceID
DeclareInterfaceID(IIOVSvc, 1, 0)
IOVTime
Basic time unit for IOVSvc. Hold time as a combination of run and event numbers.
Definition: IOVTime.h:33
IIOVSvc::preLoadDataTAD
virtual StatusCode preLoadDataTAD(const SG::TransientAddress *, const std::string &storeName="StoreGateSvc")=0
IIOVSvc::getRangeFromDB
virtual StatusCode getRangeFromDB(const CLID &clid, const std::string &key, IOVRange &range, std::string &tag, std::unique_ptr< IOpaqueAddress > &ioa) const =0
Get IOVRange from db for current event.
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
CondContBase
Base class for all conditions containers.
Definition: CondCont.h:140
DataProxy
DataProxy provides the registry services for StoreGate.
Definition: DataProxy.h:31
IIOVSvc::getTriggeredTools
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
plotBeamSpotVxVal.range
range
Definition: plotBeamSpotVxVal.py:195
IOVSvcCallBackFcn
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
IIOVSvc::setRangeInDB
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)
IIOVSvc
Abstract interface for IOVSvc. This is used (usually via StoreGateSvc regFcn and regHandle methods) t...
Definition: IIOVSvc.h:41
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
tools
Definition: DataQuality/ZLumiScripts/python/tools/__init__.py:1
compileRPVLLRates.c2
c2
Definition: compileRPVLLRates.py:361
IIOVSvc::getRange
virtual StatusCode getRange(const CLID &clid, const std::string &key, IOVRange &iov) const =0
CaloSwCorrections.time
def time(flags, cells_name, *args, **kw)
Definition: CaloSwCorrections.py:242
IIOVSvc::regFcn
virtual StatusCode regFcn(const CallBackID &c1, const CallBackID &c2, const IOVSvcCallBackFcn &fcn2, bool trigger=false)=0
register callback function
IIOVSvc::dropObjectFromDB
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.
IIOVSvc::resetAllProxies
virtual void resetAllProxies()=0
reset all proxies known to IOVSvc
IOVSvcDefs.h
defines and typedefs for IOVSvc
IIOVSvc::preLoadTAD
virtual StatusCode preLoadTAD(const SG::TransientAddress *, const std::string &storeName="StoreGateSvc")=0
pre-load transient Addresses
CaloCondBlobAlgs_fillNoiseFromASCII.tag
string tag
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:24
IIOVSvc::getStoreNames
virtual std::vector< std::string > getStoreNames() const =0
SG::DataProxy
Definition: DataProxy.h:44
IIOVSvc::regFcn
virtual StatusCode regFcn(SG::DataProxy *dp, const CallBackID &c, const IOVSvcCallBackFcn &fcn, bool trigger=false)=0
register callback function
python.compressB64.c
def c
Definition: compressB64.py:93
IIOVSvc::setRange
virtual StatusCode setRange(const CLID &clid, const std::string &key, IOVRange &, const std::string &storeName)=0
PhysDESDM_Quirks.trigger
trigger
Definition: PhysDESDM_Quirks.py:27
IIOVSvc::ignoreProxy
virtual void ignoreProxy(const CLID &clid, const std::string &key, const std::string &storeName="StoreGateSvc")=0
mapkey::key
key
Definition: TElectronEfficiencyCorrectionTool.cxx:37