Forwards messages from publishers to subscribers.
More...
#include <dispatcher.hpp>
Forwards messages from publishers to subscribers.
Definition at line 36 of file dispatcher.hpp.
◆ dispatch()
template<class T >
void event::dispatcher::dispatch |
( |
const T & |
message | ) |
const |
|
inline |
Dispatches a message to subscribers of the message type.
- Template Parameters
-
- Parameters
-
message | Message to dispatch. |
Definition at line 77 of file dispatcher.hpp.
◆ subscribe()
Subscribes a function object to messages dispatched by this dispatcher.
- Template Parameters
-
- Parameters
-
subscriber | Function object to subscribe. |
- Returns
- Shared subscription object which will unsubscribe the subscriber on destruction.
Definition at line 50 of file dispatcher.hpp.
The documentation for this class was generated from the following file: