public static interface RemoteEndpoint.Async extends RemoteEndpoint
RemoteEndpoint.Async, RemoteEndpoint.Basic
Modifier and Type | Method and Description |
---|---|
long |
getSendTimeout()
Obtain the timeout (in milliseconds) for sending a message
asynchronously.
|
Future<Void> |
sendBinary(ByteBuffer data)
Send the message asynchronously, using the Future to signal to the client
when the message has been sent.
|
void |
sendBinary(ByteBuffer data,
SendHandler completion)
Send the message asynchronously, using the SendHandler to signal to the
client when the message has been sent.
|
Future<Void> |
sendObject(Object obj) |
void |
sendObject(Object obj,
SendHandler completion) |
Future<Void> |
sendText(String text)
Send the message asynchronously, using the Future to signal to the client
when the message has been sent.
|
void |
sendText(String text,
SendHandler completion)
Send the message asynchronously, using the SendHandler to signal to the
client when the message has been sent.
|
void |
setSendTimeout(long timeout)
Set the timeout (in milliseconds) for sending a message asynchronously.
|
flushBatch, getBatchingAllowed, sendPing, sendPong, setBatchingAllowed
long getSendTimeout()
WebSocketContainer.getDefaultAsyncSendTimeout()
.void setSendTimeout(long timeout)
WebSocketContainer.getDefaultAsyncSendTimeout()
.void sendText(String text, SendHandler completion)
text
- The text message to sendcompletion
- Used to signal to the client when the message has
been sentFuture<Void> sendText(String text)
text
- The text message to sendFuture<Void> sendBinary(ByteBuffer data)
data
- The text message to sendvoid sendBinary(ByteBuffer data, SendHandler completion)
data
- The text message to sendcompletion
- Used to signal to the client when the message has
been sentvoid sendObject(Object obj, SendHandler completion)
Copyright © 2014 JBoss by Red Hat. All Rights Reserved.