Interface Publisher<E extends Event<?>>

Type Parameters:
E - the element type

public interface Publisher<E extends Event<?>>
A system publishing ActionEvent instances (such as an event bus), may implement this interface. An observable (event listener), in case of being of type Observer, may be notified using the Observer.onEvent(Event) method.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    publishEvent(E aEvent)
    The listener implementing this interface is notified of an event via this method.
  • Method Details

    • publishEvent

      void publishEvent(E aEvent)
      The listener implementing this interface is notified of an event via this method. The publisher pushes the event to the subscriber. When this method exits, then all listeners have been notified with the given event. I.e. even if each event is dispatched in an own thread, then the longest running thread determines when this method finishes.
      Parameters:
      aEvent - aEvent The event to be pushed from the publisher to the subscriber.