Interface Subscription
-
- All Superinterfaces:
java.lang.AutoCloseable,java.io.Closeable
public interface Subscription extends java.io.CloseableA SubscriptionHandler represents a subscription to an asynchronous event channel.- Since:
- 1.5
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidclose()Unsubscribes thisSubscriptionHandlerfrom receiving messages sent to this channel.java.lang.ObjectgetReturnValue()Get the return value associated with establishing this subscription.booleanisUnsubscribed()Indicates whether thisSubscriptionis currently unsubscribed.
-
-
-
Method Detail
-
close
void close()
Unsubscribes thisSubscriptionHandlerfrom receiving messages sent to this channel.- Specified by:
closein interfacejava.lang.AutoCloseable- Specified by:
closein interfacejava.io.Closeable- See Also:
ConnectorEventSubscriptionApiOp.subscribe(ObjectClass, Filter, Observer, OperationOptions),SyncEventSubscriptionApiOp.subscribe(ObjectClass, SyncToken, Observer, OperationOptions)
-
isUnsubscribed
boolean isUnsubscribed()
Indicates whether thisSubscriptionis currently unsubscribed.- Returns:
trueif thisSubscriptionis currently unsubscribed,falseotherwise
-
getReturnValue
java.lang.Object getReturnValue()
Get the return value associated with establishing this subscription.- Returns:
- return value
-
-