public interface PushNotificationHandler
| Modifier and Type | Method and Description |
|---|---|
void |
close(java.lang.String id)
Closes a subscription.
|
<T> boolean |
publish(org.cyclos.impl.utils.PushNotificationEventContext<T> context,
java.util.function.Supplier<T> dataSupplier)
Publishes a
PushNotificationEvent to a specific user session, calling the supplier and returning if the
event is really published |
java.lang.String |
subscribe(java.lang.String clientId,
java.lang.String lastEventId,
PushNotificationEventFilter filter,
java.util.function.Consumer<PushNotificationEvent<?>> listener)
Subscribes a new
PushNotificationListener for listening events of the given types,
for the user expressed in the current SessionData. |
void |
timeout(java.lang.String id)
Marks a subscription as timed-out.
|
void close(java.lang.String id)
ServiceFacade.closeSubscription(String)<T> boolean publish(org.cyclos.impl.utils.PushNotificationEventContext<T> context,
java.util.function.Supplier<T> dataSupplier)
PushNotificationEvent to a specific user session, calling the supplier and returning if the
event is really publishedjava.lang.String subscribe(java.lang.String clientId,
java.lang.String lastEventId,
PushNotificationEventFilter filter,
java.util.function.Consumer<PushNotificationEvent<?>> listener)
PushNotificationListener for listening events of the given types,
for the user expressed in the current SessionData.void timeout(java.lang.String id)