#include <event_scope.hpp>
EventScope is responsible for forwarding events to an IEventProcessor. If the given interface is nullptr, then events will not be forwarded at all.
◆ EventScope() [1/2]
launchdarkly::server_side::EventScope::EventScope |
( |
events::IEventProcessor * |
processor, |
|
|
EventFactory |
factory |
|
) |
| |
|
inline |
Constructs an EventScope with a non-owned IEventProcessor and factory. When Send is called, the factory will be passed to the caller, which must return a constructed event.
- Parameters
-
processor | The event processor to forward events to. |
factory | The factory used for generating events. |
◆ EventScope() [2/2]
launchdarkly::server_side::EventScope::EventScope |
( |
| ) |
|
|
inline |
Default constructs an EventScope which will not forward events.
◆ Send()
template<typename Callable >
void launchdarkly::server_side::EventScope::Send |
( |
Callable && |
callable | ) |
const |
|
inline |
Sends an event created by the given callable. The callable will be passed an EventFactory.
- Parameters
-
callable | Returns an InputEvent. |
The documentation for this class was generated from the following file: