![]() |
VR-Forces Developer's Guide
|
DtIInteractionEventSource - Abstract interface for a per-interaction-type event collector.
An event source subscribes to one or more VRF event manager signals in subscribe(), accumulates serialized JSON records, and exposes drain methods for consumption by a paired DtIInteractionTypeSender.
Implementations must be thread-safe: subscribe()/unsubscribe() are called on the VRF lifecycle thread, while drain methods are called from the WebSocket timer thread.
To add a new interaction type, implement this interface and register the instance with DtInteractionProcessor via addEventSource(). No changes to DtInteractionProcessor itself are required.

Public Member Functions | |
| virtual | ~DtIInteractionEventSource ()=default |
| virtual void | subscribe (makVrfEvents::DtEventManager *em)=0 |
| virtual void | unsubscribe ()=0 |
|
virtualdefault |
|
pure virtual |
Subscribe to relevant signals on em. Called once by DtInteractionProcessor::initialize().
Implemented in DtFireDetonationEventSource, and DtObjectConsoleEventSource.
|
pure virtual |
Disconnect all signal subscriptions. Called once by DtInteractionProcessor::shutdown().
Implemented in DtFireDetonationEventSource, and DtObjectConsoleEventSource.