Apache Tomcat 7.0.54

org.apache.tomcat.websocket
Class WsRemoteEndpointAsync

java.lang.Object
  extended by org.apache.tomcat.websocket.WsRemoteEndpointBase
      extended by org.apache.tomcat.websocket.WsRemoteEndpointAsync
All Implemented Interfaces:
RemoteEndpoint, RemoteEndpoint.Async

public class WsRemoteEndpointAsync
extends WsRemoteEndpointBase
implements RemoteEndpoint.Async


Nested Class Summary
 
Nested classes/interfaces inherited from interface javax.websocket.RemoteEndpoint
RemoteEndpoint.Async, RemoteEndpoint.Basic
 
Field Summary
 
Fields inherited from class org.apache.tomcat.websocket.WsRemoteEndpointBase
base
 
Method Summary
 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.
 
Methods inherited from class org.apache.tomcat.websocket.WsRemoteEndpointBase
flushBatch, getBatchingAllowed, sendPing, sendPong, setBatchingAllowed
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface javax.websocket.RemoteEndpoint
flushBatch, getBatchingAllowed, sendPing, sendPong, setBatchingAllowed
 

Method Detail

getSendTimeout

public long getSendTimeout()
Description copied from interface: javax.websocket.RemoteEndpoint.Async
Obtain the timeout (in milliseconds) for sending a message asynchronously. A non-positive value means an infinite timeout. The default value is determined by WebSocketContainer.getDefaultAsyncSendTimeout().

Specified by:
getSendTimeout in interface RemoteEndpoint.Async

setSendTimeout

public void setSendTimeout(long timeout)
Description copied from interface: javax.websocket.RemoteEndpoint.Async
Set the timeout (in milliseconds) for sending a message asynchronously. A non-positive value means an infinite timeout. The default value is determined by WebSocketContainer.getDefaultAsyncSendTimeout().

Specified by:
setSendTimeout in interface RemoteEndpoint.Async

sendText

public void sendText(String text,
                     SendHandler completion)
Description copied from interface: javax.websocket.RemoteEndpoint.Async
Send the message asynchronously, using the SendHandler to signal to the client when the message has been sent.

Specified by:
sendText in interface RemoteEndpoint.Async
Parameters:
text - The text message to send
completion - Used to signal to the client when the message has been sent

sendText

public Future<Void> sendText(String text)
Description copied from interface: javax.websocket.RemoteEndpoint.Async
Send the message asynchronously, using the Future to signal to the client when the message has been sent.

Specified by:
sendText in interface RemoteEndpoint.Async
Parameters:
text - The text message to send

sendBinary

public Future<Void> sendBinary(ByteBuffer data)
Description copied from interface: javax.websocket.RemoteEndpoint.Async
Send the message asynchronously, using the Future to signal to the client when the message has been sent.

Specified by:
sendBinary in interface RemoteEndpoint.Async
Parameters:
data - The text message to send

sendBinary

public void sendBinary(ByteBuffer data,
                       SendHandler completion)
Description copied from interface: javax.websocket.RemoteEndpoint.Async
Send the message asynchronously, using the SendHandler to signal to the client when the message has been sent.

Specified by:
sendBinary in interface RemoteEndpoint.Async
Parameters:
data - The text message to send
completion - Used to signal to the client when the message has been sent

sendObject

public Future<Void> sendObject(Object obj)
Specified by:
sendObject in interface RemoteEndpoint.Async

sendObject

public void sendObject(Object obj,
                       SendHandler completion)
Specified by:
sendObject in interface RemoteEndpoint.Async

Apache Tomcat 7.0.54

Copyright © 2000-2014 Apache Software Foundation. All Rights Reserved.