|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.atmosphere.websocket.WebSocketAdapter
org.atmosphere.container.version.TomcatWebSocket
public class TomcatWebSocket
Tomcat WebSocket Support
| Field Summary |
|---|
| Fields inherited from class org.atmosphere.websocket.WebSocketAdapter |
|---|
lastWrite |
| Fields inherited from interface org.atmosphere.websocket.WebSocket |
|---|
WEBSOCKET_ACCEPT_DONE, WEBSOCKET_INITIATED, WEBSOCKET_RESUME, WEBSOCKET_SUSPEND |
| Constructor Summary | |
|---|---|
TomcatWebSocket(org.apache.catalina.websocket.WsOutbound outbound,
AtmosphereConfig config)
|
|
| Method Summary | |
|---|---|
void |
close()
Close the underlying connection. |
void |
flush()
Flush the buffered content |
void |
redirect(String location)
Redirect a WebSocket request to another location |
String |
toString()
|
void |
write(byte[] data)
Write a WebSocket message |
void |
write(byte[] data,
int offset,
int length)
Write a WebSocket message |
void |
write(String data)
Write a WebSocket message |
void |
writeError(int errorCode,
String message)
Write an error code |
| Methods inherited from class org.atmosphere.websocket.WebSocketAdapter |
|---|
lastTick, resource, setAtmosphereResource |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public TomcatWebSocket(org.apache.catalina.websocket.WsOutbound outbound,
AtmosphereConfig config)
| Method Detail |
|---|
public void redirect(String location)
throws IOException
AsyncIOWriter
IOException
public void writeError(int errorCode,
String message)
throws IOException
AsyncIOWriter
errorCode - the error code
IOException
public void write(String data)
throws IOException
AsyncIOWriter
data - the WebSocket message
IOException
public void write(byte[] data)
throws IOException
data - the WebSocket message
IOException
public void write(byte[] data,
int offset,
int length)
throws IOException
data - the WebSocket messageoffset - offset of the messagelength - length if the message
IOException
public void close()
throws IOException
close in interface AsyncIOWriterclose in class WebSocketAdapterIOException
public void flush()
throws IOException
IOExceptionpublic String toString()
toString in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||