Members
-
enabled :boolean
-
Details
Methods
-
on( eventType, func ) → {NexusHoratio.base.Dispatcher}
-
Description
Attach a function to an eventType.
Parameters
Name Type Description eventTypeNexusHoratio.base.Dispatcher~EventType Event type to connect with.
funcNexusHoratio.base.Dispatcher~Handler Single argument function to call.
Returns
Details
-
off( eventType, func ) → {NexusHoratio.base.Dispatcher}
-
Description
Remove all instances of a function registered to an eventType.
Parameters
Name Type Description eventTypeNexusHoratio.base.Dispatcher~EventType Event type to disconnect from.
funcNexusHoratio.base.Dispatcher~Handler Function to remove.
Returns
Details
-
fire( eventType, data ) → {NexusHoratio.base.Dispatcher}
-
Description
Calls all registered functions for the given eventType.
Parameters
Name Type Description eventTypeNexusHoratio.base.Dispatcher~EventType Event type to use.
dataobject Data to pass to each function.
Returns
Details
Type Definitions
-
EventType
-
Details
-
Handler( eventType, data )
-
Parameters
Name Type Description eventTypeNexusHoratio.base.Dispatcher~EventType Event type.
dataobject Event data.
Details