Show / Hide Table of Contents

Interface ISubscriber<TEvent>

The ISubscriber interface that all subscribers have to implement. This interface is needed, so that the EventBus can publish events of the exact type without having to cast at compile time.

Namespace:
Assembly: .dll
Syntax
public interface ISubscriber<TEvent>
Type Parameters
Name Description
TEvent

Methods

getSubscribedEventType()

Gets the subscribed events simple name.

Declaration
public abstract String getSubscribedEventType()
Returns
Type Description
java.lang.String

The subscribed events simple name

notify(TEvent event)

Called when a TEvent is published at the EventBus subscribed to. The subscriber is notified with the concrete event.

Declaration
public abstract void notify(TEvent event)
Parameters
Type Name Description
TEvent event

THe event published to the EventBus

In This Article
Back to top Generated by DocFX