Package org.apache.tomcat.websocket
Class WsRemoteEndpointAsync
java.lang.Object
org.apache.tomcat.websocket.WsRemoteEndpointBase
org.apache.tomcat.websocket.WsRemoteEndpointAsync
- All Implemented Interfaces:
- RemoteEndpoint,- RemoteEndpoint.Async
- 
Nested Class SummaryNested classes/interfaces inherited from interface jakarta.websocket.RemoteEndpointRemoteEndpoint.Async, RemoteEndpoint.Basic
- 
Field SummaryFields inherited from class org.apache.tomcat.websocket.WsRemoteEndpointBasebase
- 
Method SummaryModifier and TypeMethodDescriptionlongObtain the timeout (in milliseconds) for sending a message asynchronously.sendBinary(ByteBuffer data) Send the message asynchronously, using the Future to signal to the client when the message has been sent.voidsendBinary(ByteBuffer data, SendHandler completion) Send the message asynchronously, using the SendHandler to signal to the client when the message has been sent.sendObject(Object obj) Encodes object as a message and sends it asynchronously, using the Future to signal to the client when the message has been sent.voidsendObject(Object obj, SendHandler completion) Encodes object as a message and sends it asynchronously, using the SendHandler to signal to the client when the message has been sent.Send the message asynchronously, using the Future to signal to the client when the message has been sent.voidsendText(String text, SendHandler completion) Send the message asynchronously, using the SendHandler to signal to the client when the message has been sent.voidsetSendTimeout(long timeout) Set the timeout (in milliseconds) for sending a message asynchronously.Methods inherited from class org.apache.tomcat.websocket.WsRemoteEndpointBaseflushBatch, getBatchingAllowed, sendPing, sendPong, setBatchingAllowedMethods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface jakarta.websocket.RemoteEndpointflushBatch, getBatchingAllowed, sendPing, sendPong, setBatchingAllowed
- 
Method Details- 
getSendTimeoutpublic long getSendTimeout()Description copied from interface:jakarta.websocket.RemoteEndpoint.AsyncObtain the timeout (in milliseconds) for sending a message asynchronously. The default value is determined byWebSocketContainer.getDefaultAsyncSendTimeout().- Specified by:
- getSendTimeoutin interface- RemoteEndpoint.Async
- Returns:
- The current send timeout in milliseconds. A non-positive value means an infinite timeout.
 
- 
setSendTimeoutpublic void setSendTimeout(long timeout) Description copied from interface:jakarta.websocket.RemoteEndpoint.AsyncSet the timeout (in milliseconds) for sending a message asynchronously. The default value is determined byWebSocketContainer.getDefaultAsyncSendTimeout().- Specified by:
- setSendTimeoutin interface- RemoteEndpoint.Async
- Parameters:
- timeout- The new timeout for sending messages asynchronously in milliseconds. A non-positive value means an infinite timeout.
 
- 
sendTextDescription copied from interface:jakarta.websocket.RemoteEndpoint.AsyncSend the message asynchronously, using the SendHandler to signal to the client when the message has been sent.- Specified by:
- sendTextin interface- RemoteEndpoint.Async
- Parameters:
- text- The text message to send
- completion- Used to signal to the client when the message has been sent
 
- 
sendTextDescription copied from interface:jakarta.websocket.RemoteEndpoint.AsyncSend the message asynchronously, using the Future to signal to the client when the message has been sent.- Specified by:
- sendTextin interface- RemoteEndpoint.Async
- Parameters:
- text- The text message to send
- Returns:
- A Future that signals when the message has been sent.
 
- 
sendBinaryDescription copied from interface:jakarta.websocket.RemoteEndpoint.AsyncSend the message asynchronously, using the Future to signal to the client when the message has been sent.- Specified by:
- sendBinaryin interface- RemoteEndpoint.Async
- Parameters:
- data- The text message to send
- Returns:
- A Future that signals when the message has been sent.
 
- 
sendBinaryDescription copied from interface:jakarta.websocket.RemoteEndpoint.AsyncSend the message asynchronously, using the SendHandler to signal to the client when the message has been sent.- Specified by:
- sendBinaryin interface- RemoteEndpoint.Async
- Parameters:
- data- The text message to send
- completion- Used to signal to the client when the message has been sent
 
- 
sendObjectDescription copied from interface:jakarta.websocket.RemoteEndpoint.AsyncEncodes object as a message and sends it asynchronously, using the Future to signal to the client when the message has been sent.- Specified by:
- sendObjectin interface- RemoteEndpoint.Async
- Parameters:
- obj- The object to be sent.
- Returns:
- A Future that signals when the message has been sent.
 
- 
sendObjectDescription copied from interface:jakarta.websocket.RemoteEndpoint.AsyncEncodes object as a message and sends it asynchronously, using the SendHandler to signal to the client when the message has been sent.- Specified by:
- sendObjectin interface- RemoteEndpoint.Async
- Parameters:
- obj- The object to be sent.
- completion- Used to signal to the client when the message has been sent
 
 
-