26 lines
610 B
Java
26 lines
610 B
Java
package envoy.client.event;
|
|
|
|
import java.util.Set;
|
|
|
|
/**
|
|
* Project: <strong>envoy-clientChess</strong><br>
|
|
* File: <strong>EventHandler.javaEvent.java</strong><br>
|
|
* Created: <strong>04.12.2019</strong><br>
|
|
*
|
|
* @author Kai S. K. Engelbart
|
|
*/
|
|
public interface EventHandler {
|
|
|
|
/**
|
|
* Consumes an event dispatched by the event bus.
|
|
*
|
|
* @param event The event dispatched by the event bus, only of supported type
|
|
*/
|
|
void handle(Event<?> event);
|
|
|
|
/**
|
|
* @return A set of classes this class is supposed to handle in events
|
|
*/
|
|
Set<Class<? extends Event<?>>> supports();
|
|
}
|