|
EventBus
Overview of the event bus
IntroductionThe main idea is to decouple your code. The EventBus is a global communication channel that all the blocks in your application have access to. Basically you subscribe to an event and get notified when someone fires it from any part of your application. Here is a diagram of how the EventBus plays with Guit.
ObservationIt is important to notice that you should never subscribe directly to an eventBus event as you used to do before: eventBus.addHandler(....); You should use Guit's EventBinders. | |