Package org.apache.tomcat.jdbc.pool
Class ConnectionPool.ConnectionFuture
java.lang.Object
org.apache.tomcat.jdbc.pool.ConnectionPool.ConnectionFuture
- All Implemented Interfaces:
- Runnable,- Future<Connection>
- Enclosing class:
- ConnectionPool
protected class ConnectionPool.ConnectionFuture
extends Object
implements Future<Connection>, Runnable
Thread safe wrapper around a future for the regular queue
 This one retrieves the pooled connection object
 and performs the initialization according to
 interceptors and validation rules.
 This class is thread safe and is cancellable
- 
Constructor Details- 
ConnectionFuture
- 
ConnectionFuture- Throws:
- SQLException
 
 
- 
- 
Method Details- 
cancelpublic boolean cancel(boolean mayInterruptIfRunning) - Specified by:
- cancelin interface- Future<Connection>
 
- 
get- Specified by:
- getin interface- Future<Connection>
- Throws:
- InterruptedException
- ExecutionException
 
- 
getpublic Connection get(long timeout, TimeUnit unit) throws InterruptedException, ExecutionException, TimeoutException - Specified by:
- getin interface- Future<Connection>
- Throws:
- InterruptedException
- ExecutionException
- TimeoutException
 
- 
isCancelledpublic boolean isCancelled()- Specified by:
- isCancelledin interface- Future<Connection>
 
- 
isDonepublic boolean isDone()- Specified by:
- isDonein interface- Future<Connection>
 
- 
runpublic void run()run method to be executed when cancelled by an executor
 
-