Class ConnectionPoolDataSourceRelay

  • All Implemented Interfaces:
    Relay<javax.sql.ConnectionPoolDataSource>, javax.sql.CommonDataSource, javax.sql.ConnectionPoolDataSource

    public class ConnectionPoolDataSourceRelay
    extends java.lang.Object
    implements Relay<javax.sql.ConnectionPoolDataSource>, javax.sql.ConnectionPoolDataSource
    • Field Summary

      Fields 
      Modifier and Type Field Description
      com.impossibl.jdbc.spy.ConnectionPoolDataSourceListener listener  
      javax.sql.ConnectionPoolDataSource target  
    • Constructor Summary

      Constructors 
      Constructor Description
      ConnectionPoolDataSourceRelay​(javax.sql.ConnectionPoolDataSource target, com.impossibl.jdbc.spy.ConnectionPoolDataSourceListener listener)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int getLoginTimeout()  
      java.io.PrintWriter getLogWriter()  
      java.util.logging.Logger getParentLogger()  
      javax.sql.PooledConnection getPooledConnection()  
      javax.sql.PooledConnection getPooledConnection​(java.lang.String user, java.lang.String password)  
      javax.sql.ConnectionPoolDataSource getTarget()  
      void setLoginTimeout​(int seconds)  
      void setLogWriter​(java.io.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 javax.sql.ConnectionPoolDataSource target
      • listener

        public com.impossibl.jdbc.spy.ConnectionPoolDataSourceListener listener
    • Constructor Detail

      • ConnectionPoolDataSourceRelay

        public ConnectionPoolDataSourceRelay​(javax.sql.ConnectionPoolDataSource target,
                                             com.impossibl.jdbc.spy.ConnectionPoolDataSourceListener listener)
    • Method Detail

      • getTarget

        public javax.sql.ConnectionPoolDataSource getTarget()
        Specified by:
        getTarget in interface Relay<javax.sql.ConnectionPoolDataSource>
      • getPooledConnection

        public javax.sql.PooledConnection getPooledConnection​(java.lang.String user,
                                                              java.lang.String password)
                                                       throws java.sql.SQLException
        Specified by:
        getPooledConnection in interface javax.sql.ConnectionPoolDataSource
        Throws:
        java.sql.SQLException
      • setLoginTimeout

        public void setLoginTimeout​(int seconds)
                             throws java.sql.SQLException
        Specified by:
        setLoginTimeout in interface javax.sql.CommonDataSource
        Specified by:
        setLoginTimeout in interface javax.sql.ConnectionPoolDataSource
        Throws:
        java.sql.SQLException
      • getPooledConnection

        public javax.sql.PooledConnection getPooledConnection()
                                                       throws java.sql.SQLException
        Specified by:
        getPooledConnection in interface javax.sql.ConnectionPoolDataSource
        Throws:
        java.sql.SQLException
      • setLogWriter

        public void setLogWriter​(java.io.PrintWriter out)
                          throws java.sql.SQLException
        Specified by:
        setLogWriter in interface javax.sql.CommonDataSource
        Specified by:
        setLogWriter in interface javax.sql.ConnectionPoolDataSource
        Throws:
        java.sql.SQLException
      • getParentLogger

        public java.util.logging.Logger getParentLogger()
                                                 throws java.sql.SQLFeatureNotSupportedException
        Specified by:
        getParentLogger in interface javax.sql.CommonDataSource
        Throws:
        java.sql.SQLFeatureNotSupportedException
      • getLoginTimeout

        public int getLoginTimeout()
                            throws java.sql.SQLException
        Specified by:
        getLoginTimeout in interface javax.sql.CommonDataSource
        Specified by:
        getLoginTimeout in interface javax.sql.ConnectionPoolDataSource
        Throws:
        java.sql.SQLException
      • getLogWriter

        public java.io.PrintWriter getLogWriter()
                                         throws java.sql.SQLException
        Specified by:
        getLogWriter in interface javax.sql.CommonDataSource
        Specified by:
        getLogWriter in interface javax.sql.ConnectionPoolDataSource
        Throws:
        java.sql.SQLException