com.caucho.network.listen
Interface SocketLinkDuplexListener

All Known Implementing Classes:
WebSocketModule.QuercusWebSocketListener, XmppBrokerStream

public interface SocketLinkDuplexListener

Resin network handler for a bidirectional tcp stream. The read stream should only be read by the onRead thread. The write stream must be synchronized if it's every written by a thread other than the serviceRead


Method Summary
 void onDisconnect(SocketLinkDuplexController context)
          Called when the connection closes
 void onRead(SocketLinkDuplexController context)
          Called when read data is available
 void onStart(SocketLinkDuplexController context)
          Called when the connection is established
 void onTimeout(SocketLinkDuplexController context)
          Called when the connection times out
 

Method Detail

onStart

void onStart(SocketLinkDuplexController context)
             throws java.io.IOException
Called when the connection is established

Throws:
java.io.IOException

onRead

void onRead(SocketLinkDuplexController context)
            throws java.io.IOException
Called when read data is available

Throws:
java.io.IOException

onDisconnect

void onDisconnect(SocketLinkDuplexController context)
                  throws java.io.IOException
Called when the connection closes

Throws:
java.io.IOException

onTimeout

void onTimeout(SocketLinkDuplexController context)
               throws java.io.IOException
Called when the connection times out

Throws:
java.io.IOException