Class that can handle event dispatching. Users can register event handlers for certain events and when the emit() function is called, this class will take care of invoking all of the event handlers that were registered for events of that type.
emit()
Private
Fires the event, calling all registered listeners with the provided arguments.
The event name.
Rest
The arguments for the listeners.
Removes a listener for the event.
The listener callback.
Registers a new listener for the event.
A function that removes the listener when called.
Class that can handle event dispatching. Users can register event handlers for certain events and when the
emit()
function is called, this class will take care of invoking all of the event handlers that were registered for events of that type.