com.github.edgar615.util.eventbus.EventFuture Maven / Gradle / Ivy
package com.github.edgar615.util.eventbus;
import com.github.edgar615.util.event.Event;
public interface EventFuture {
Event event();
boolean isComplete();
EventFuture setCallback(Callback callback);
void complete(T result);
void fail(Throwable throwable);
T result();
Throwable cause();
boolean succeeded();
boolean failed();
static EventFuture future(Event event) {
return new EventFutureImpl<>(event);
}
}