vecty: Index | Files

package dispatcher

import ""


Package Files


func Dispatch Uses

func Dispatch(action interface{})

Dispatch dispatches the given action to all registered callbacks.

func Unregister Uses

func Unregister(id ID)

Unregister unregisters the callback previously registered via a call to Register.

type ID Uses

type ID int

ID is a unique identifier representing a registered callback function.

func Register Uses

func Register(callback func(action interface{})) ID

Register registers the callback to handle dispatched actions, the returned ID may be used to unregister the callback later.

Package dispatcher is imported by 3 packages. Updated 2017-09-05. Refresh now. Tools for package owners.