fr.paris.lutece.util.pool.service
Class LuteceConnectionService

java.lang.Object
  extended by fr.paris.lutece.util.pool.service.LuteceConnectionService
All Implemented Interfaces:
ConnectionService

public class LuteceConnectionService
extends java.lang.Object
implements ConnectionService

Lutece Connection Service


Constructor Summary
LuteceConnectionService()
           
 
Method Summary
 void freeConnection(java.sql.Connection conn)
          Free the connection
 java.sql.Connection getConnection()
          Get a connection
 ConnectionPool getConnectionPool()
          Returns the coonection pool
 org.apache.log4j.Logger getLogger()
          Gets the pool logger
 java.lang.String getPoolName()
          Returns the pool name
 void init(java.util.Hashtable<java.lang.String,java.lang.String> htParamsConnectionPool)
          Initializes the connection pool
 void release()
          Release the pool
 void setLogger(org.apache.log4j.Logger logger)
          Sets the logger
 void setPoolName(java.lang.String strPoolName)
          Sets the pool name
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LuteceConnectionService

public LuteceConnectionService()
Method Detail

setPoolName

public void setPoolName(java.lang.String strPoolName)
Sets the pool name

Specified by:
setPoolName in interface ConnectionService
Parameters:
strPoolName - The pool name

getPoolName

public java.lang.String getPoolName()
Returns the pool name

Specified by:
getPoolName in interface ConnectionService
Returns:
The pool name

setLogger

public void setLogger(org.apache.log4j.Logger logger)
Sets the logger

Specified by:
setLogger in interface ConnectionService
Parameters:
logger - The logger

getLogger

public org.apache.log4j.Logger getLogger()
Gets the pool logger

Specified by:
getLogger in interface ConnectionService
Returns:
The logger

init

public void init(java.util.Hashtable<java.lang.String,java.lang.String> htParamsConnectionPool)
Initializes the connection pool

Specified by:
init in interface ConnectionService
Parameters:
htParamsConnectionPool - Pool parameters

getConnection

public java.sql.Connection getConnection()
Get a connection

Specified by:
getConnection in interface ConnectionService
Returns:
A connection

freeConnection

public void freeConnection(java.sql.Connection conn)
Free the connection

Specified by:
freeConnection in interface ConnectionService
Parameters:
conn - The connection to release

release

public void release()
Release the pool

Specified by:
release in interface ConnectionService

getConnectionPool

public ConnectionPool getConnectionPool()
Returns the coonection pool

Returns:
the coonection pool


Copyright © 2008 Mairie de Paris. All Rights Reserved.