KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > snaq > db > ConnectionValidator


1 /*
2     DBPool - JDBC Connection Pool Manager
3     Copyright (c) Giles Winstanley
4 */

5 package snaq.db;
6
7 import java.sql.*;
8
9 /**
10  * Interface for validating database connections.
11  * This interface can be implemented by a class in order to provide custom
12  * database connection validation. To use the custom validator class make
13  * sure you call the <tt>setValidator</tt> method in either the
14  * <tt>ConnectionPool</tt> object or the <tt>ConnectionPoolManager</tt>
15  * in your code (or use the properties file version with the pool manager).
16  * @author Giles Winstanley
17  */

18 public interface ConnectionValidator
19 {
20     boolean isValid(Connection con);
21 }
Popular Tags