org.atmosphere.container.version
Class Jetty8WebSocket

java.lang.Object
  extended by org.atmosphere.cpr.AsyncIOWriterAdapter
      extended by org.atmosphere.websocket.WebSocket
          extended by org.atmosphere.container.version.Jetty8WebSocket
All Implemented Interfaces:
AsyncIOWriter

public class Jetty8WebSocket
extends WebSocket

Jetty 8 WebSocket support.

Author:
Jeanfrancois Arcand

Field Summary
 
Fields inherited from class org.atmosphere.websocket.WebSocket
binaryWrite, lastWrite, WEBSOCKET_ACCEPT_DONE, WEBSOCKET_INITIATED, WEBSOCKET_RESUME, WEBSOCKET_SUSPEND, webSocketResponseFilter
 
Constructor Summary
Jetty8WebSocket(org.eclipse.jetty.websocket.WebSocket.Connection connection, AtmosphereConfig config)
           
 
Method Summary
 void close(AtmosphereResponse r)
          No OPS
 WebSocket flush(AtmosphereResponse r)
          No OPS
 WebSocket redirect(AtmosphereResponse r, String location)
          No OPS
 String toString()
           
 WebSocket write(AtmosphereResponse r, byte[] data)
          No OPS
 WebSocket write(AtmosphereResponse r, byte[] data, int offset, int length)
          No OPS
 WebSocket write(AtmosphereResponse r, String data)
          No OPS
 WebSocket writeError(AtmosphereResponse r, int errorCode, String message)
          No OPS
 
Methods inherited from class org.atmosphere.websocket.WebSocket
config, lastWriteTimeStampInMilliseconds, resource, resource, retrieveUUID, webSocketResponseFilter
 
Methods inherited from class org.atmosphere.cpr.AsyncIOWriterAdapter
close, flush, redirect, write, write, write, writeError
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Jetty8WebSocket

public Jetty8WebSocket(org.eclipse.jetty.websocket.WebSocket.Connection connection,
                       AtmosphereConfig config)
Method Detail

writeError

public WebSocket writeError(AtmosphereResponse r,
                            int errorCode,
                            String message)
                     throws IOException
No OPS

Specified by:
writeError in interface AsyncIOWriter
Overrides:
writeError in class AsyncIOWriterAdapter
errorCode - the error code
Throws:
IOException

redirect

public WebSocket redirect(AtmosphereResponse r,
                          String location)
                   throws IOException
No OPS

Specified by:
redirect in interface AsyncIOWriter
Overrides:
redirect in class AsyncIOWriterAdapter
Throws:
IOException

write

public WebSocket write(AtmosphereResponse r,
                       String data)
                throws IOException
No OPS

Specified by:
write in interface AsyncIOWriter
Overrides:
write in class AsyncIOWriterAdapter
data - the WebSocket message
Throws:
IOException

write

public WebSocket write(AtmosphereResponse r,
                       byte[] data)
                throws IOException
No OPS

Specified by:
write in interface AsyncIOWriter
Overrides:
write in class AsyncIOWriterAdapter
data - the WebSocket message
Throws:
IOException

write

public WebSocket write(AtmosphereResponse r,
                       byte[] data,
                       int offset,
                       int length)
                throws IOException
No OPS

Specified by:
write in interface AsyncIOWriter
Overrides:
write in class AsyncIOWriterAdapter
data - the WebSocket message
offset - offset of the message
length - length if the message
Throws:
IOException

close

public void close(AtmosphereResponse r)
           throws IOException
No OPS

Specified by:
close in interface AsyncIOWriter
Overrides:
close in class AsyncIOWriterAdapter
Throws:
IOException

flush

public WebSocket flush(AtmosphereResponse r)
                throws IOException
No OPS

Specified by:
flush in interface AsyncIOWriter
Overrides:
flush in class AsyncIOWriterAdapter
Throws:
IOException

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2013. All Rights Reserved.