Package org.somda.sdc.dpws.service
Interface EventSinkAccess
-
- All Known Implementing Classes:
HostedServiceProxyImpl
public interface EventSinkAccessOffers access to event sink functionality in accordance with WS-Eventing.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description com.google.common.util.concurrent.ListenableFuture<Duration>getStatus(String subscriptionId)Gets the status of a subscription.com.google.common.util.concurrent.ListenableFuture<Duration>renew(String subscriptionId, Duration expires)Renews a subscription.com.google.common.util.concurrent.ListenableFuture<SubscribeResult>subscribe(List<String> actions, Duration expires, Interceptor notificationSink)Conducts a subscribe.com.google.common.util.concurrent.ListenableFutureunsubscribe(String subscriptionId)Unsubscribes from a subscription.voidunsubscribeAll()Synchronously unsubscribes all subscriptions.
-
-
-
Method Detail
-
subscribe
com.google.common.util.concurrent.ListenableFuture<SubscribeResult> subscribe(List<String> actions, @Nullable Duration expires, Interceptor notificationSink)
Conducts a subscribe.- Parameters:
actions- a list of operation actions to subscribe for.expires- the desired expiration time (the hosted service may decide to grant lesser than this). If none is given, the hosting service will take decision.notificationSink- the sink where to deliver notifications.- Returns:
- a future object that either includes subscription information or throws
-
renew
com.google.common.util.concurrent.ListenableFuture<Duration> renew(String subscriptionId, Duration expires)
Renews a subscription.- Parameters:
subscriptionId- the subscription id obtained in theSubscribeResultofsubscribe(List, Duration, Interceptor).expires- the desired new expiration duration.- Returns:
- a future object that either includes a granted expires duration or throws
-
getStatus
com.google.common.util.concurrent.ListenableFuture<Duration> getStatus(String subscriptionId)
Gets the status of a subscription.- Parameters:
subscriptionId- the subscription id obtained in theSubscribeResultofsubscribe(List, Duration, Interceptor).- Returns:
- a future object that either includes the remaining subscription time or throws
-
unsubscribe
com.google.common.util.concurrent.ListenableFuture unsubscribe(String subscriptionId)
Unsubscribes from a subscription.- Parameters:
subscriptionId- the subscription id obtained in theSubscribeResultofsubscribe(List, Duration, Interceptor).- Returns:
- a future object that either delivers an empty object in case of successful unsubscribe or throws
-
unsubscribeAll
void unsubscribeAll()
Synchronously unsubscribes all subscriptions.- See Also:
EventSink.unsubscribeAll()
-
-