This commit is contained in:
Looly
2024-01-09 23:15:52 +08:00
parent 64c1dc554b
commit ebf1632f36
6 changed files with 31 additions and 30 deletions

View File

@@ -71,52 +71,52 @@ public class DSWrapper extends SimpleWrapper<DataSource> implements DataSource,
@Override
public PrintWriter getLogWriter() throws SQLException {
return getRaw().getLogWriter();
return this.raw.getLogWriter();
}
@Override
public void setLogWriter(final PrintWriter out) throws SQLException {
getRaw().setLogWriter(out);
this.raw.setLogWriter(out);
}
@Override
public void setLoginTimeout(final int seconds) throws SQLException {
getRaw().setLoginTimeout(seconds);
this.raw.setLoginTimeout(seconds);
}
@Override
public int getLoginTimeout() throws SQLException {
return getRaw().getLoginTimeout();
return this.raw.getLoginTimeout();
}
@Override
public Logger getParentLogger() throws SQLFeatureNotSupportedException {
return getRaw().getParentLogger();
return this.raw.getParentLogger();
}
@Override
public <T> T unwrap(final Class<T> iface) throws SQLException {
return getRaw().unwrap(iface);
return this.raw.unwrap(iface);
}
@Override
public boolean isWrapperFor(final Class<?> iface) throws SQLException {
return getRaw().isWrapperFor(iface);
return this.raw.isWrapperFor(iface);
}
@Override
public Connection getConnection() throws SQLException {
return getRaw().getConnection();
return this.raw.getConnection();
}
@Override
public Connection getConnection(final String username, final String password) throws SQLException {
return getRaw().getConnection(username, password);
return this.raw.getConnection(username, password);
}
@Override
public void close() {
final DataSource ds = getRaw();
final DataSource ds = this.raw;
if (ds instanceof AutoCloseable) {
IoUtil.closeQuietly((AutoCloseable) ds);
}