com.caucho.server.connection
Class ConnectionController

java.lang.Object
  extended by com.caucho.server.connection.ConnectionController
Direct Known Subclasses:
HttpConnectionController, TcpDuplexController

public class ConnectionController
extends java.lang.Object

Controls a tcp connection for comet.


Constructor Summary
protected ConnectionController(Connection conn)
          Creates a new TcpConnectionController.
 
Method Summary
 void close()
          Closes the connection.
 Connection getConnection()
           
 boolean isActive()
          Returns true if the connection is active.
 boolean isClosed()
          Returns true if the connection is active.
 boolean isDuplex()
          Returns true for a duplex controller
 boolean isTimeout()
          Return true if timed out
 void timeout()
          Sets the timeout.
 boolean wake()
          Wakes the connection.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConnectionController

protected ConnectionController(Connection conn)
Creates a new TcpConnectionController.

Parameters:
conn - The TCP connection
Method Detail

getConnection

public Connection getConnection()

wake

public final boolean wake()
Wakes the connection.


isDuplex

public boolean isDuplex()
Returns true for a duplex controller


timeout

public final void timeout()
Sets the timeout.


isTimeout

public final boolean isTimeout()
Return true if timed out


isActive

public final boolean isActive()
Returns true if the connection is active.


isClosed

public final boolean isClosed()
Returns true if the connection is active.


close

public void close()
Closes the connection.