ATLAS Offline Software
EventIDFromStore.h
Go to the documentation of this file.
1 // This file's extension implies that it's C, but it's really -*- C++ -*-.
2 
3 /*
4  Copyright (C) 2002-2019 CERN for the benefit of the ATLAS collaboration
5 */
6 
14 #ifndef SGTOOLS_EVENTIDFROMSTORE_H
15 #define SGTOOLS_EVENTIDFROMSTORE_H
16 
17 #include "StoreGate/StoreGateSvc.h"
18 
19 class IProxyDict;
20 class EventIDBase;
21 
28 const EventIDBase* EventIDFromStore( IProxyDict* store );
29 
30 // variation accepting a ServiceHandle to StoreGate
31 const EventIDBase* EventIDFromStore( const ServiceHandle<StoreGateSvc>& storeH )
32 {
33  return EventIDFromStore( &*storeH );
34 }
35 
36 
37 // variation returning a StatusCode
38 StatusCode EventIDFromStore( IProxyDict* store, const EventIDBase*& evid )
39 {
40  evid = EventIDFromStore( store );
41  return evid? StatusCode::SUCCESS : StatusCode::FAILURE;
42 }
43 
44 #endif
45 
store
StoreGateSvc * store
Definition: fbtTestBasics.cxx:69
IProxyDict
A proxy dictionary.
Definition: AthenaKernel/AthenaKernel/IProxyDict.h:51
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
EventIDFromStore
const EventIDBase * EventIDFromStore(IProxyDict *store)
Retrieve the EventID from EventContext saved in store STORE.
Definition: EventIDFromStore.cxx:15
StoreGateSvc.h
ServiceHandle< StoreGateSvc >