![]() |
Project
|
#include <CallbackService.h>
Public Member Functions | |
template<Id ID, typename U > | |
void | set (U &&cb) |
template<Id ID, typename... TArgs> | |
auto | call (TArgs &&... args) |
Static Public Attributes | |
static constexpr ServiceKind | service_kind = ServiceKind::Global |
Definition at line 34 of file CallbackService.h.
Definition at line 107 of file CallbackService.h.
using o2::framework::CallbackService::CCDBDeserializedCallback = std::function<void(ConcreteDataMatcher&, void*)> |
Definition at line 102 of file CallbackService.h.
using o2::framework::CallbackService::ClockTickCallback = std::function<void()> |
Definition at line 94 of file CallbackService.h.
using o2::framework::CallbackService::DataConsumedCallback = std::function<void(ServiceRegistryRef)> |
Definition at line 95 of file CallbackService.h.
using o2::framework::CallbackService::DeviceStateChangedCallback = std::function<void(ServiceRegistryRef, int newState)> |
Definition at line 104 of file CallbackService.h.
using o2::framework::CallbackService::DomainInfoUpdatedCallback = std::function<void(ServiceRegistryRef, size_t timeslice, ChannelIndex index)> |
Definition at line 103 of file CallbackService.h.
using o2::framework::CallbackService::EndOfStreamCallback = std::function<void(EndOfStreamContext&)> |
Definition at line 96 of file CallbackService.h.
using o2::framework::CallbackService::ExitRequestedCallback = std::function<void(ServiceRegistryRef)> |
Definition at line 105 of file CallbackService.h.
using o2::framework::CallbackService::FinaliseOutputsCallback = std::function<void(ServiceRegistryRef, int)> |
Definition at line 100 of file CallbackService.h.
using o2::framework::CallbackService::IdleCallback = std::function<void()> |
Definition at line 93 of file CallbackService.h.
using o2::framework::CallbackService::NewTimesliceCallback = std::function<void(o2::header::DataHeader&, DataProcessingHeader&)> |
Definition at line 98 of file CallbackService.h.
using o2::framework::CallbackService::PostProcessingCallback = std::function<void(ServiceRegistryRef, int)> |
Definition at line 101 of file CallbackService.h.
using o2::framework::CallbackService::PreProcessingCallback = std::function<void(ServiceRegistryRef, int)> |
Definition at line 99 of file CallbackService.h.
using o2::framework::CallbackService::RegionInfoCallback = std::function<void(fair::mq::RegionInfo const&)> |
Definition at line 97 of file CallbackService.h.
using o2::framework::CallbackService::ResetCallback = std::function<void()> |
Definition at line 92 of file CallbackService.h.
using o2::framework::CallbackService::StartCallback = std::function<void()> |
Definition at line 90 of file CallbackService.h.
using o2::framework::CallbackService::StopCallback = std::function<void()> |
Definition at line 91 of file CallbackService.h.
|
strong |
the defined processing steps at which a callback can be invoked
Enumerator | |
---|---|
Start | Invoked before the inner loop is started |
Stop | Invoked when the device is about to be stoped |
Reset | Invoked on device rest |
Idle | Invoked when there was no computation scheduled |
ClockTick | Invoked every iteration of the inner loop |
DataConsumed | Invoked whenever data has been consumed |
EndOfStream | Invoked when we are notified that no further data will arrive. Notice that one could have more "EndOfData" notifications. Because we could be signaled by control that the data flow restarted. |
RegionInfoCallback | Invoked whenever FairMQ notifies us of a new region return AlgorithmSpec::InitCallback{[=](InitContext& ic) { auto& callbacks = ic.services().get<CallbackService>(); callbacks.set<CallbackService::Id::RegionInfoCallback>([](fair::mq::RegionInfo const& info) { ... do GPU init ... }); } ... return [task](ProcessingContext& pc) { // your processing loop. Guaranteed to be called synchronously // with the callback }; }}; |
NewTimeslice | Invoked whenever a new timeslice has been created from an enumeration. Users can override this to make sure the fill the DataHeader associated to a timeslice with the wanted quantities. |
PreProcessing | Invoked before the processing callback. |
FinaliseOutputs | Invoked after the processing callback and before the post processing callback to allow for injecting data in the output stream. |
PostProcessing | Invoked after the processing callback,. |
CCDBDeserialised | Invoked whenever an object from CCDB is deserialised via ROOT. Use this to finalise the initialisation of the object. |
DomainInfoUpdated | Invoked when new domain info is available. |
DeviceStateChanged | Invoked the device undergoes a state change. |
ExitRequested | Invoked when the device was requested to stop. |
Definition at line 41 of file CallbackService.h.
|
inline |
Definition at line 134 of file CallbackService.h.
Definition at line 127 of file CallbackService.h.
|
staticconstexpr |
Callbacks are a global service because they will always be invoked by the main thread only.
Definition at line 39 of file CallbackService.h.