| java.lang.Object snaq.util.LogUtil snaq.util.ObjectPool snaq.db.ConnectionPool
Constructor Summary | |
public | ConnectionPool(String name, int poolSize, int maxSize, long expiryTime, String url, String username, String password) Creates new connection pool. | public | ConnectionPool(String name, int poolSize, int maxSize, long expiryTime, String url, Properties props) Creates new connection pool. |
ConnectionPool | public ConnectionPool(String name, int poolSize, int maxSize, long expiryTime, String url, String username, String password)(Code) | | Creates new connection pool.
Parameters: name - pool name Parameters: poolSize - maximum number of pooled objects, or 0 for no limit Parameters: maxSize - maximum number of possible objects, or 0 for no limit Parameters: expiryTime - expiry time (milliseconds) for pooled object, or 0 for no expiry Parameters: url - JDBC connection URL Parameters: username - database username Parameters: password - password for the database username supplied |
ConnectionPool | public ConnectionPool(String name, int poolSize, int maxSize, long expiryTime, String url, Properties props)(Code) | | Creates new connection pool.
Parameters: name - pool name Parameters: poolSize - maximum number of pooled objects, or 0 for no limit Parameters: maxSize - maximum number of possible objects, or 0 for no limit Parameters: expiryTime - expiry time (milliseconds) for pooled object, or 0 for no expiry Parameters: url - JDBC connection URL Parameters: props - connection properties |
addConnectionPoolListener | final public void addConnectionPoolListener(ConnectionPoolListener x)(Code) | | Adds an ConnectionPoolListener to the event notification list.
|
compareTo | public int compareTo(Object o)(Code) | | Compares this instances to other instances by name.
|
destroy | protected void destroy(Reusable o)(Code) | | Closes the given connection.
|
freeConnection | protected void freeConnection(Connection c) throws SQLException(Code) | | Returns a connection to the pool (for internal use only).
Connections obtained from the pool should be returned by calling the
close() method on the connection.
|
getPasswordDecoder | public PasswordDecoder getPasswordDecoder()(Code) | | Returns the current password decoder class.
|
isValid | protected boolean isValid(Reusable o)(Code) | | Validates a connection.
|
removeConnectionPoolListener | final public void removeConnectionPoolListener(ConnectionPoolListener x)(Code) | | Removes an ConnectionPoolListener from the event notification list.
|
setCaching | public void setCaching(boolean b)(Code) | | Determines whether to perform statement caching.
This applies to all types of statements (normal, prepared, callable).
|
setCaching | public void setCaching(boolean ss, boolean ps, boolean cs)(Code) | | Determines whether to perform statement caching.
Parameters: ss - whether to cache Statement objects Parameters: ps - whether to cache PreparedStatement objects Parameters: cs - whether to cache CallableStatement objects |
setPasswordDecoder | public void setPasswordDecoder(PasswordDecoder pd)(Code) | | Sets the password decoder class.
|
toString | public String toString()(Code) | | Returns a descriptive string for this pool instance.
|
|
|