public class ReactorNettyTcpStompClient extends StompClientSupport
ReactorNettyTcpClient
.Constructor and Description |
---|
ReactorNettyTcpStompClient()
Create an instance with host "127.0.0.1" and port 61613.
|
ReactorNettyTcpStompClient(String host,
int port)
Create an instance with the given host and port.
|
ReactorNettyTcpStompClient(TcpOperations<byte[]> tcpClient)
Create an instance with a pre-configured TCP client.
|
Modifier and Type | Method and Description |
---|---|
ListenableFuture<StompSession> |
connect(StompHeaders connectHeaders,
StompSessionHandler handler)
An overloaded version of
connect(StompSessionHandler) that
accepts headers to use for the STOMP CONNECT frame. |
ListenableFuture<StompSession> |
connect(StompSessionHandler handler)
Connect and notify the given
StompSessionHandler when connected
on the STOMP level. |
void |
shutdown()
Shut down the client and release resources.
|
createSession, getDefaultHeartbeat, getMessageConverter, getReceiptTimeLimit, getTaskScheduler, isDefaultHeartbeatEnabled, processConnectHeaders, setDefaultHeartbeat, setMessageConverter, setReceiptTimeLimit, setTaskScheduler
public ReactorNettyTcpStompClient()
public ReactorNettyTcpStompClient(String host, int port)
host
- the hostport
- the portpublic ReactorNettyTcpStompClient(TcpOperations<byte[]> tcpClient)
tcpClient
- the client to usepublic ListenableFuture<StompSession> connect(StompSessionHandler handler)
StompSessionHandler
when connected
on the STOMP level.handler
- the handler for the STOMP sessionpublic ListenableFuture<StompSession> connect(@Nullable StompHeaders connectHeaders, StompSessionHandler handler)
connect(StompSessionHandler)
that
accepts headers to use for the STOMP CONNECT frame.connectHeaders
- headers to add to the CONNECT framehandler
- the handler for the STOMP sessionpublic void shutdown()