![]() |
Project
|
A text based way of communicating with the driver. More...
#include <TextDriverClient.h>
Inherits o2::framework::DriverClient.
Public Member Functions | |
| TextDriverClient (ServiceRegistryRef registry, DeviceState &deviceState) | |
| void | tell (char const *msg, size_t s, bool flush=true) final |
| void | flushPending (ServiceRegistryRef ref) final |
Public Member Functions inherited from o2::framework::DriverClient | |
| void | tell (std::string_view const &msg, bool flush=true) |
| void | observe (char const *eventType, std::function< void(std::string_view)> callback) |
| Request action on some eventType notified by the driver. | |
| void | dispatch (std::string_view event) |
| Dispatch an event. | |
Static Public Attributes | |
| static constexpr ServiceKind | service_kind = ServiceKind::Global |
Static Public Attributes inherited from o2::framework::DriverClient | |
| static constexpr ServiceKind | service_kind = ServiceKind::Global |
A text based way of communicating with the driver.
Definition at line 24 of file TextDriverClient.h.
| o2::framework::TextDriverClient::TextDriverClient | ( | ServiceRegistryRef | registry, |
| DeviceState & | deviceState | ||
| ) |
Definition at line 17 of file TextDriverClient.cxx.
|
finalvirtual |
Flush all pending events (if connected) Note: this must be guaranteed to be called from the main thread, because the libuv backend cannot queue write operations on a thread which is not the main one. In order to do this, one should have assert(mainTreadRef.isMainThread()) in the implementation. Notice also that if you want to use uv_async_send, you must make sure that you do not rely on having as many events as the times you called uv_async_send, because this is not guaranteed.
Implements o2::framework::DriverClient.
Definition at line 26 of file TextDriverClient.cxx.
|
finalvirtual |
The text based client simply sends a message on stdout which is (potentially) captured by the driver.
Implements o2::framework::DriverClient.
Definition at line 21 of file TextDriverClient.cxx.
|
staticconstexpr |
Definition at line 27 of file TextDriverClient.h.