org.abstracthorizon.danube.support.logging
Class AccessLogConnectionHandler.DateWrapper

java.lang.Object
  extended by org.abstracthorizon.danube.connection.ConnectionWrapper
      extended by org.abstracthorizon.danube.support.logging.AccessLogConnectionHandler.DateWrapper
All Implemented Interfaces:
Adaptable, Connection
Enclosing class:
AccessLogConnectionHandler

public static class AccessLogConnectionHandler.DateWrapper
extends ConnectionWrapper

Simple connection wrapper that adds handling started time in milliseconds

Author:
Daniel Sendula

Field Summary
 
Fields inherited from class org.abstracthorizon.danube.connection.ConnectionWrapper
connection, logger
 
Constructor Summary
AccessLogConnectionHandler.DateWrapper(Connection connection, long handlingStarted)
          Constructor
 
Method Summary
<T> T
adapt(Class<T> cls)
          If this class is request than returns this object otherwise calls super method
 long getHandlingStarted()
          Returns handling started time
 
Methods inherited from class org.abstracthorizon.danube.connection.ConnectionWrapper
close, isClosed
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AccessLogConnectionHandler.DateWrapper

public AccessLogConnectionHandler.DateWrapper(Connection connection,
                                              long handlingStarted)
Constructor

Parameters:
connection - connection to be wrapped
handlingStarted - handling started time
Method Detail

getHandlingStarted

public long getHandlingStarted()
Returns handling started time

Returns:
handling started time

adapt

public <T> T adapt(Class<T> cls)
If this class is request than returns this object otherwise calls super method

Specified by:
adapt in interface Adaptable
Overrides:
adapt in class ConnectionWrapper
Parameters:
cls - class to be adapted to
Returns:
adapted object or nothing


Copyright © 2005-2009 Abstract Horizon. All Rights Reserved.