Code example for EventBus

Methods: register

0
 
    public PurchaseEventSubscriber(EventBus eventBus) { 
        super(eventBus); 
    } 
 
    @Override 
    @Subscribe 
    public void handleEvent(PurchaseEvent event) { 
        events.add(event); 
    } 
 
 
}