@ProviderType
public interface AsyncConnectable
Modifier and Type | Method and Description |
---|---|
<T> CompletableFuture<T> |
connectAsync()
Connects asynchronously with a PubSub+ event broker.
|
<T> void |
connectAsync(CompletionListener<T> connectionListener)
Connects asynchronously with a PubSub+ event broker with a callback.
|
CompletableFuture<Void> |
disconnectAsync()
Disconnects asynchronously with a PubSub+ event broker.
|
void |
disconnectAsync(CompletionListener<Void> disconnectionListener)
Disconnects asynchronously with a PubSub+ event broker with a callback.
|
<T> CompletableFuture<T> connectAsync() throws PubSubPlusClientException, IllegalStateException
PubSubPlusClientException
- if the messaging service cannot be connectedIllegalStateException
- if an attempt to connect to a messaging service that's been
disconnected<T> void connectAsync(CompletionListener<T> connectionListener) throws PubSubPlusClientException, IllegalStateException
connectionListener
- the callback for future notifications about completion state of the
connection processPubSubPlusClientException
- if the messaging service cannot be connectedIllegalStateException
- if an attempt to connect to a messaging service that's been
disconnectedCompletableFuture<Void> disconnectAsync() throws PubSubPlusClientException, IllegalStateException
PubSubPlusClientException
- if the messaging service cannot be disconnectedIllegalStateException
void disconnectAsync(CompletionListener<Void> disconnectionListener) throws PubSubPlusClientException, IllegalStateException
disconnectionListener
- the callback for future notifications about completion of the
disconnection processPubSubPlusClientException
- if the messaging service cannot be disconnectedIllegalStateException
- if a service is in an inappropriate state to perform a
disconnectCopyright 2019-2024 Solace Corporation. All rights reserved.