ingo@1127: /* ingo@1127: * Copyright (c) 2010 by Intevation GmbH ingo@1127: * ingo@1127: * This program is free software under the LGPL (>=v2.1) ingo@1127: * Read the file LGPL.txt coming with the software for details ingo@1127: * or visit http://www.gnu.org/licenses/ if it does not exist. ingo@1127: */ ingo@1127: tim@130: package de.intevation.gnv.geobackend.base.connectionpool; tim@130: sascha@886: import de.intevation.gnv.geobackend.base.connectionpool.exception.ConnectionException; sascha@886: tim@130: import java.sql.Connection; sascha@886: tim@130: import java.util.Properties; tim@130: tim@130: /** tim@130: * Interfacedefinition for an Generic ConnectionPool sascha@887: * @author Tim Englich tim@130: */ tim@130: public interface ConnectionPool { sascha@885: tim@132: /** tim@132: * Delivers the Connection to the Database sascha@885: * @param connectionID the ID of the Connection tim@132: * @return the Connection to the Database tim@132: * @throws ConnectionException tim@132: */ tim@132: public Connection getConnection(String connectionID) throws ConnectionException; tim@132: tim@132: /** tim@132: * Returns the Connection to the Pool tim@132: * @param connection the Connection which should be returned to the Pool tim@132: * @throws ConnectionException tim@132: */ tim@132: public void closeConnection(Connection connection) throws ConnectionException; tim@132: tim@132: /** tim@132: * Initializes the ConnectionPool tim@132: * @param properties The Properties which should be used for initializing theConnectionPool tim@132: */ tim@132: public void initialize(Properties properties); tim@130: tim@130: }