jodd.db.pool
Interface ConnectionPool

All Known Implementing Classes:
ContextConnectionPool, CoreConnectionPool, NoConnectionPool, OracleConnectionPool

public interface ConnectionPool

A database connection pool interface.


Method Summary
 void close()
          Close pool when it is not needed anymore.
 void freeConnection(java.sql.Connection conn)
          Returns connection to connection pool.
 java.sql.Connection getConnection()
          Get one free connection from the connection pool.
 void init()
          Initialize pool with current object state.
 

Method Detail

init

public void init()
          throws java.sql.SQLException
Initialize pool with current object state.

Throws:
java.sql.SQLException

getConnection

public java.sql.Connection getConnection()
                                  throws java.sql.SQLException
Get one free connection from the connection pool.

Returns:
Connection object representing free database connection
Throws:
java.sql.SQLException

freeConnection

public void freeConnection(java.sql.Connection conn)
Returns connection to connection pool.

Parameters:
conn - database connection

close

public void close()
Close pool when it is not needed anymore.



Jodd v0.24.5 Javadoc