Package org.apache.tomcat.websocket
Class WsRemoteEndpointBasic
- java.lang.Object
- 
- org.apache.tomcat.websocket.WsRemoteEndpointBase
- 
- org.apache.tomcat.websocket.WsRemoteEndpointBasic
 
 
- 
- All Implemented Interfaces:
- RemoteEndpoint,- RemoteEndpoint.Basic
 
 public class WsRemoteEndpointBasic extends WsRemoteEndpointBase implements RemoteEndpoint.Basic 
- 
- 
Nested Class Summary- 
Nested classes/interfaces inherited from interface javax.websocket.RemoteEndpointRemoteEndpoint.Async, RemoteEndpoint.Basic
 
- 
 - 
Field Summary- 
Fields inherited from class org.apache.tomcat.websocket.WsRemoteEndpointBasebase
 
- 
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description java.io.OutputStreamgetSendStream()java.io.WritergetSendWriter()voidsendBinary(java.nio.ByteBuffer data)Send the message, blocking until the message is sent.voidsendBinary(java.nio.ByteBuffer partialByte, boolean isLast)Sends part of a binary message to the remote endpoint.voidsendObject(java.lang.Object o)Encodes object as a message and sends it to the remote endpoint.voidsendText(java.lang.String text)Send the message, blocking until the message is sent.voidsendText(java.lang.String fragment, boolean isLast)Sends part of a text message to the remote endpoint.- 
Methods inherited from class org.apache.tomcat.websocket.WsRemoteEndpointBaseflushBatch, getBatchingAllowed, sendPing, sendPong, setBatchingAllowed
 - 
Methods inherited from class java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - 
Methods inherited from interface javax.websocket.RemoteEndpointflushBatch, getBatchingAllowed, sendPing, sendPong, setBatchingAllowed
 
- 
 
- 
- 
- 
Method Detail- 
sendTextpublic void sendText(java.lang.String text) throws java.io.IOExceptionDescription copied from interface:javax.websocket.RemoteEndpoint.BasicSend the message, blocking until the message is sent.- Specified by:
- sendTextin interface- RemoteEndpoint.Basic
- Parameters:
- text- The text message to send.
- Throws:
- java.io.IOException- if an I/O error occurs during the sending of the message.
 
 - 
sendBinarypublic void sendBinary(java.nio.ByteBuffer data) throws java.io.IOExceptionDescription copied from interface:javax.websocket.RemoteEndpoint.BasicSend the message, blocking until the message is sent.- Specified by:
- sendBinaryin interface- RemoteEndpoint.Basic
- Parameters:
- data- The binary message to send
- Throws:
- java.io.IOException- if an I/O error occurs during the sending of the message.
 
 - 
sendTextpublic void sendText(java.lang.String fragment, boolean isLast) throws java.io.IOExceptionDescription copied from interface:javax.websocket.RemoteEndpoint.BasicSends part of a text message to the remote endpoint. Once the first part of a message has been sent, no other text or binary messages may be sent until all remaining parts of this message have been sent.- Specified by:
- sendTextin interface- RemoteEndpoint.Basic
- Parameters:
- fragment- The partial message to send
- isLast-- trueif this is the last part of the message, otherwise- false
- Throws:
- java.io.IOException- if an I/O error occurs during the sending of the message.
 
 - 
sendBinarypublic void sendBinary(java.nio.ByteBuffer partialByte, boolean isLast) throws java.io.IOExceptionDescription copied from interface:javax.websocket.RemoteEndpoint.BasicSends part of a binary message to the remote endpoint. Once the first part of a message has been sent, no other text or binary messages may be sent until all remaining parts of this message have been sent.- Specified by:
- sendBinaryin interface- RemoteEndpoint.Basic
- Parameters:
- partialByte- The partial message to send
- isLast-- trueif this is the last part of the message, otherwise- false
- Throws:
- java.io.IOException- if an I/O error occurs during the sending of the message.
 
 - 
getSendStreampublic java.io.OutputStream getSendStream() throws java.io.IOException- Specified by:
- getSendStreamin interface- RemoteEndpoint.Basic
- Throws:
- java.io.IOException
 
 - 
getSendWriterpublic java.io.Writer getSendWriter() throws java.io.IOException- Specified by:
- getSendWriterin interface- RemoteEndpoint.Basic
- Throws:
- java.io.IOException
 
 - 
sendObjectpublic void sendObject(java.lang.Object o) throws java.io.IOException, EncodeExceptionDescription copied from interface:javax.websocket.RemoteEndpoint.BasicEncodes object as a message and sends it to the remote endpoint.- Specified by:
- sendObjectin interface- RemoteEndpoint.Basic
- Parameters:
- o- The object to be sent.
- Throws:
- java.io.IOException- if an I/O error occurs during the sending of the message.
- EncodeException- if there was a problem encoding the- dataobject as a websocket message.
 
 
- 
 
-