Interface class for managing ROB for both online and offline.
More...
#include <IROBDataProviderSvc.h>
|
| DeclareInterfaceID (IROBDataProviderSvc, 1, 1) |
| Retrieve interface ID. More...
|
|
virtual void | addROBData (const EventContext &context, const std::vector< uint32_t > &robIds, const std::string_view callerName="UNKNOWN")=0 |
| Add ROBFragments to cache for given ROB ids, ROB fragments may be retrieved with DataCollector. More...
|
|
virtual void | setNextEvent (const EventContext &context, const std::vector< ROBF > &result)=0 |
| Add a given LVL1/LVL2 ROBFragment to cache. More...
|
|
virtual void | setNextEvent (const EventContext &context, const RawEvent *re)=0 |
| Add all ROBFragments of a RawEvent to cache. More...
|
|
virtual void | getROBData (const EventContext &context, const std::vector< uint32_t > &robIds, VROBFRAG &robFragments, const std::string_view callerName="UNKNOWN")=0 |
| Retrieve ROBFragments for given ROB ids from cache. More...
|
|
virtual const RawEvent * | getEvent (const EventContext &context)=0 |
| Retrieve the whole event. More...
|
|
virtual void | setEventStatus (const EventContext &context, uint32_t)=0 |
| Store the status for the event. More...
|
|
virtual uint32_t | getEventStatus (const EventContext &context)=0 |
| Retrieve the status for the event. More...
|
|
virtual void | processCachedROBs (const EventContext &context, const std::function< void(const ROBF *)> &fn) const =0 |
| Interface to access cache of ROBs (it is a full event in case of offline) In online implementation the cache will contain only a subset of ROBs. More...
|
|
virtual bool | isEventComplete (const EventContext &) const =0 |
| Check if complete event data are already in cache. More...
|
|
virtual int | collectCompleteEventData (const EventContext &context, const std::string_view callerName="UNKNOWN")=0 |
| Collect all data for an event from the ROS and put them into the cache. More...
|
|
Interface class for managing ROB for both online and offline.
Definition at line 23 of file IROBDataProviderSvc.h.
◆ ROBF
◆ VROBFRAG
◆ addROBData()
virtual void IROBDataProviderSvc::addROBData |
( |
const EventContext & |
context, |
|
|
const std::vector< uint32_t > & |
robIds, |
|
|
const std::string_view |
callerName = "UNKNOWN" |
|
) |
| |
|
pure virtual |
Add ROBFragments to cache for given ROB ids, ROB fragments may be retrieved with DataCollector.
◆ collectCompleteEventData()
virtual int IROBDataProviderSvc::collectCompleteEventData |
( |
const EventContext & |
context, |
|
|
const std::string_view |
callerName = "UNKNOWN" |
|
) |
| |
|
pure virtual |
Collect all data for an event from the ROS and put them into the cache.
- Returns
- value: number of ROBs which were retrieved to complete the event Optionally the name of the caller of this method can be specified for monitoring
◆ DeclareInterfaceID()
◆ getEvent()
Retrieve the whole event.
◆ getEventStatus()
virtual uint32_t IROBDataProviderSvc::getEventStatus |
( |
const EventContext & |
context | ) |
|
|
pure virtual |
Retrieve the status for the event.
◆ getROBData()
virtual void IROBDataProviderSvc::getROBData |
( |
const EventContext & |
context, |
|
|
const std::vector< uint32_t > & |
robIds, |
|
|
VROBFRAG & |
robFragments, |
|
|
const std::string_view |
callerName = "UNKNOWN" |
|
) |
| |
|
pure virtual |
Retrieve ROBFragments for given ROB ids from cache.
◆ isEventComplete()
virtual bool IROBDataProviderSvc::isEventComplete |
( |
const EventContext & |
| ) |
const |
|
pure virtual |
Check if complete event data are already in cache.
◆ processCachedROBs()
virtual void IROBDataProviderSvc::processCachedROBs |
( |
const EventContext & |
context, |
|
|
const std::function< void(const ROBF *)> & |
fn |
|
) |
| const |
|
pure virtual |
Interface to access cache of ROBs (it is a full event in case of offline) In online implementation the cache will contain only a subset of ROBs.
This method allows read access to the cache.
- Warning
- in case the cache is updated in the meantime the iteration is guaranteed to be safe but may not give access to all the ROBs available n the very moment Example of counting: size_t counter = 0; svc->processCahcedROBs(ctx, [&](const ROBF*){ counter ++; }) Example of printout: svc->processCahcedROBs(ctx, [&](const ROBF* rob){ log() << MSG::DEBUG << "ROB " << rob->source_id() << endmsg; })
◆ setEventStatus()
virtual void IROBDataProviderSvc::setEventStatus |
( |
const EventContext & |
context, |
|
|
uint32_t |
|
|
) |
| |
|
pure virtual |
Store the status for the event.
◆ setNextEvent() [1/2]
virtual void IROBDataProviderSvc::setNextEvent |
( |
const EventContext & |
context, |
|
|
const RawEvent * |
re |
|
) |
| |
|
pure virtual |
Add all ROBFragments of a RawEvent to cache.
◆ setNextEvent() [2/2]
virtual void IROBDataProviderSvc::setNextEvent |
( |
const EventContext & |
context, |
|
|
const std::vector< ROBF > & |
result |
|
) |
| |
|
pure virtual |
Add a given LVL1/LVL2 ROBFragment to cache.
The documentation for this class was generated from the following file: