Package com.impossibl.jdbc.spy
Class ConnectionPoolDataSourceRelay
- java.lang.Object
-
- com.impossibl.jdbc.spy.ConnectionPoolDataSourceRelay
-
- All Implemented Interfaces:
Relay<ConnectionPoolDataSource>,CommonDataSource,ConnectionPoolDataSource
public class ConnectionPoolDataSourceRelay extends Object implements Relay<ConnectionPoolDataSource>, ConnectionPoolDataSource
-
-
Field Summary
Fields Modifier and Type Field Description com.impossibl.jdbc.spy.ConnectionPoolDataSourceListenerlistenerConnectionPoolDataSourcetarget
-
Constructor Summary
Constructors Constructor Description ConnectionPoolDataSourceRelay(ConnectionPoolDataSource target, com.impossibl.jdbc.spy.ConnectionPoolDataSourceListener listener)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetLoginTimeout()PrintWritergetLogWriter()LoggergetParentLogger()PooledConnectiongetPooledConnection()PooledConnectiongetPooledConnection(String user, String password)ConnectionPoolDataSourcegetTarget()voidsetLoginTimeout(int seconds)voidsetLogWriter(PrintWriter out)-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface javax.sql.CommonDataSource
createShardingKeyBuilder
-
Methods inherited from interface javax.sql.ConnectionPoolDataSource
createPooledConnectionBuilder
-
-
-
-
Field Detail
-
target
public ConnectionPoolDataSource target
-
listener
public com.impossibl.jdbc.spy.ConnectionPoolDataSourceListener listener
-
-
Constructor Detail
-
ConnectionPoolDataSourceRelay
public ConnectionPoolDataSourceRelay(ConnectionPoolDataSource target, com.impossibl.jdbc.spy.ConnectionPoolDataSourceListener listener)
-
-
Method Detail
-
getTarget
public ConnectionPoolDataSource getTarget()
- Specified by:
getTargetin interfaceRelay<ConnectionPoolDataSource>
-
setLoginTimeout
public void setLoginTimeout(int seconds) throws SQLException- Specified by:
setLoginTimeoutin interfaceCommonDataSource- Specified by:
setLoginTimeoutin interfaceConnectionPoolDataSource- Throws:
SQLException
-
getPooledConnection
public PooledConnection getPooledConnection(String user, String password) throws SQLException
- Specified by:
getPooledConnectionin interfaceConnectionPoolDataSource- Throws:
SQLException
-
getLoginTimeout
public int getLoginTimeout() throws SQLException- Specified by:
getLoginTimeoutin interfaceCommonDataSource- Specified by:
getLoginTimeoutin interfaceConnectionPoolDataSource- Throws:
SQLException
-
getLogWriter
public PrintWriter getLogWriter() throws SQLException
- Specified by:
getLogWriterin interfaceCommonDataSource- Specified by:
getLogWriterin interfaceConnectionPoolDataSource- Throws:
SQLException
-
getPooledConnection
public PooledConnection getPooledConnection() throws SQLException
- Specified by:
getPooledConnectionin interfaceConnectionPoolDataSource- Throws:
SQLException
-
getParentLogger
public Logger getParentLogger() throws SQLFeatureNotSupportedException
- Specified by:
getParentLoggerin interfaceCommonDataSource- Throws:
SQLFeatureNotSupportedException
-
setLogWriter
public void setLogWriter(PrintWriter out) throws SQLException
- Specified by:
setLogWriterin interfaceCommonDataSource- Specified by:
setLogWriterin interfaceConnectionPoolDataSource- Throws:
SQLException
-
-