Package com.impossibl.jdbc.spy
Class XADataSourceRelay
- java.lang.Object
-
- com.impossibl.jdbc.spy.XADataSourceRelay
-
- All Implemented Interfaces:
Relay<XADataSource>
,CommonDataSource
,XADataSource
public class XADataSourceRelay extends Object implements Relay<XADataSource>, XADataSource
-
-
Field Summary
Fields Modifier and Type Field Description com.impossibl.jdbc.spy.XADataSourceListener
listener
XADataSource
target
-
Constructor Summary
Constructors Constructor Description XADataSourceRelay(XADataSource target, com.impossibl.jdbc.spy.XADataSourceListener listener)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getLoginTimeout()
PrintWriter
getLogWriter()
Logger
getParentLogger()
XADataSource
getTarget()
XAConnection
getXAConnection()
XAConnection
getXAConnection(String user, String password)
void
setLoginTimeout(int seconds)
void
setLogWriter(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.XADataSource
createXAConnectionBuilder
-
-
-
-
Field Detail
-
target
public XADataSource target
-
listener
public com.impossibl.jdbc.spy.XADataSourceListener listener
-
-
Constructor Detail
-
XADataSourceRelay
public XADataSourceRelay(XADataSource target, com.impossibl.jdbc.spy.XADataSourceListener listener)
-
-
Method Detail
-
getTarget
public XADataSource getTarget()
- Specified by:
getTarget
in interfaceRelay<XADataSource>
-
setLoginTimeout
public void setLoginTimeout(int seconds) throws SQLException
- Specified by:
setLoginTimeout
in interfaceCommonDataSource
- Specified by:
setLoginTimeout
in interfaceXADataSource
- Throws:
SQLException
-
getLogWriter
public PrintWriter getLogWriter() throws SQLException
- Specified by:
getLogWriter
in interfaceCommonDataSource
- Specified by:
getLogWriter
in interfaceXADataSource
- Throws:
SQLException
-
getXAConnection
public XAConnection getXAConnection() throws SQLException
- Specified by:
getXAConnection
in interfaceXADataSource
- Throws:
SQLException
-
getXAConnection
public XAConnection getXAConnection(String user, String password) throws SQLException
- Specified by:
getXAConnection
in interfaceXADataSource
- Throws:
SQLException
-
getLoginTimeout
public int getLoginTimeout() throws SQLException
- Specified by:
getLoginTimeout
in interfaceCommonDataSource
- Specified by:
getLoginTimeout
in interfaceXADataSource
- Throws:
SQLException
-
setLogWriter
public void setLogWriter(PrintWriter out) throws SQLException
- Specified by:
setLogWriter
in interfaceCommonDataSource
- Specified by:
setLogWriter
in interfaceXADataSource
- Throws:
SQLException
-
getParentLogger
public Logger getParentLogger() throws SQLFeatureNotSupportedException
- Specified by:
getParentLogger
in interfaceCommonDataSource
- Throws:
SQLFeatureNotSupportedException
-
-