SPARK
0.1.0
A general purpose game engine written in C++.
|
A class that dispatches events to the appropriate event handler. More...
#include <EventDispatcher.h>
Public Member Functions | |
EventDispatcher (Event &event) | |
Instantiates a new EventDispatcher for the given event. | |
EventDispatcher (const EventDispatcher &other)=delete | |
EventDispatcher (EventDispatcher &&other) noexcept=delete | |
EventDispatcher & | operator= (const EventDispatcher &other)=delete |
EventDispatcher & | operator= (EventDispatcher &&other) noexcept=delete |
template<typename T , typename F > | |
bool | dispatch (const F &func) |
Dispatches the event to the appropriate event handler. | |
A class that dispatches events to the appropriate event handler.
|
explicit |
Instantiates a new EventDispatcher for the given event.
event | the event to dispatch. |
|
nodiscard |
Dispatches the event to the appropriate event handler.
T | The type of the event to dispatch. |
F | The type of the event handler (automatically deduced). |
func | The event handler to call. |