org.eclipse.jetty.websocket
Class WebSocketConnection

java.lang.Object
  extended by org.eclipse.jetty.websocket.WebSocketConnection
All Implemented Interfaces:
Connection, WebSocket.Outbound

public class WebSocketConnection
extends Object
implements Connection, WebSocket.Outbound


Constructor Summary
WebSocketConnection(Connector connector, WebSocketBuffers buffers, EndPoint endpoint, long timestamp, WebSocket websocket)
           
 
Method Summary
 void disconnect()
           
 void fill(Buffer buffer)
           
 long getTimeStamp()
           
 void handle()
           
 boolean isIdle()
           
 boolean isOpen()
           
 boolean isSuspended()
           
 void sendMessage(byte frame, byte[] content)
           
 void sendMessage(byte frame, byte[] content, int offset, int length)
           
 void sendMessage(byte frame, String content)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WebSocketConnection

public WebSocketConnection(Connector connector,
                           WebSocketBuffers buffers,
                           EndPoint endpoint,
                           long timestamp,
                           WebSocket websocket)
Method Detail

handle

public void handle()
            throws IOException
Specified by:
handle in interface Connection
Throws:
IOException

isOpen

public boolean isOpen()
Specified by:
isOpen in interface WebSocket.Outbound

isIdle

public boolean isIdle()
Specified by:
isIdle in interface Connection

isSuspended

public boolean isSuspended()
Specified by:
isSuspended in interface Connection

getTimeStamp

public long getTimeStamp()
Specified by:
getTimeStamp in interface Connection

sendMessage

public void sendMessage(byte frame,
                        String content)
                 throws IOException
Specified by:
sendMessage in interface WebSocket.Outbound
Throws:
IOException

sendMessage

public void sendMessage(byte frame,
                        byte[] content)
                 throws IOException
Specified by:
sendMessage in interface WebSocket.Outbound
Throws:
IOException

sendMessage

public void sendMessage(byte frame,
                        byte[] content,
                        int offset,
                        int length)
                 throws IOException
Specified by:
sendMessage in interface WebSocket.Outbound
Throws:
IOException

disconnect

public void disconnect()
Specified by:
disconnect in interface WebSocket.Outbound

fill

public void fill(Buffer buffer)


Copyright © 1995-2009 Mort Bay Consulting. All Rights Reserved.