Interface IEventManager

    • Method Detail

      • register

        void register​(@Nonnull
                      Object listener)
        Registers the specified listener
        Accepted types may be specified by implementations
        Parameters:
        listener - A listener object
        Throws:
        UnsupportedOperationException - If the implementation does not support this method
      • unregister

        void unregister​(@Nonnull
                        Object listener)
        Removes the specified listener
        Parameters:
        listener - The listener object to remove
        Throws:
        UnsupportedOperationException - If the implementation does not support this method
      • handle

        void handle​(@Nonnull
                    GenericEvent event)
        Handles the provided GenericEvent.
        How this is handled is specified by the implementation.

        An implementation should not throw exceptions.

        Parameters:
        event - The event to handle
      • getRegisteredListeners

        @Nonnull
        List<Object> getRegisteredListeners()
        The currently registered listeners
        Returns:
        A list of listeners that have already been registered
        Throws:
        UnsupportedOperationException - If the implementation does not support this method