com.echomine.net
Class TimeableConnection

java.lang.Object
  extended by com.echomine.net.Connection
      extended by com.echomine.net.TimeableConnection
Direct Known Subclasses:
HandshakeableSocketAcceptor, HandshakeableSocketConnector, JabberConnection, SocketAcceptor, SocketConnector

public class TimeableConnection
extends Connection

Adds a feature that will record the amount of time since the connection is online. This time is started when established event is fired, and stops when closed event is fired. This class simply utilizes the available features in ConnectionModel


Field Summary
 
Fields inherited from class com.echomine.net.Connection
listenerList
 
Constructor Summary
TimeableConnection()
           
 
Method Summary
protected  void fireConnectionClosed(ConnectionEvent event)
           
protected  void fireConnectionEstablished(ConnectionEvent event)
           
 
Methods inherited from class com.echomine.net.Connection
addConnectionListener, fireConnectionStarting, fireConnectionStartingWithoutVeto, removeConnectionListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TimeableConnection

public TimeableConnection()
Method Detail

fireConnectionEstablished

protected void fireConnectionEstablished(ConnectionEvent event)
Overrides:
fireConnectionEstablished in class Connection

fireConnectionClosed

protected void fireConnectionClosed(ConnectionEvent event)
Overrides:
fireConnectionClosed in class Connection


Copyright © 2001-2005 Echomine. All Rights Reserved.