diff --git a/src/main/java/uk/co/uwcs/choob/support/ChoobConnectionWrapper.java b/src/main/java/uk/co/uwcs/choob/support/ChoobConnectionWrapper.java index 86f85f6..2829e5a 100644 --- a/src/main/java/uk/co/uwcs/choob/support/ChoobConnectionWrapper.java +++ b/src/main/java/uk/co/uwcs/choob/support/ChoobConnectionWrapper.java @@ -20,6 +20,7 @@ import java.sql.Struct; import java.util.Map; import java.util.Properties; +import java.util.concurrent.Executor; public final class ChoobConnectionWrapper implements Connection { @@ -237,4 +238,27 @@ public ChoobConnectionWrapper(final Connection conn) { @Override public T unwrap(final Class iface) throws SQLException { return conn.unwrap(iface); } + + public void setSchema(String schema) throws SQLException { + // silently ignoring is fine + } + + public String getSchema() throws SQLException { + // null is an acceptable return value + return null; + } + + public void abort(Executor executor) throws SQLException { + throw new SQLException("Method stub; not available in Java 6 and not supported: abort"); + } + + public void setNetworkTimeout(Executor executor, int milliseconds) throws SQLException { + throw new SQLException("Method stub; not available in Java 6 and not supported: setNetworkTimeout"); + + } + + public int getNetworkTimeout() throws SQLException { + // no timeout; acceptable + return 0; + } } diff --git a/src/main/java/uk/co/uwcs/choob/support/ChoobStatementWrapper.java b/src/main/java/uk/co/uwcs/choob/support/ChoobStatementWrapper.java index d7e33e9..c2facd4 100644 --- a/src/main/java/uk/co/uwcs/choob/support/ChoobStatementWrapper.java +++ b/src/main/java/uk/co/uwcs/choob/support/ChoobStatementWrapper.java @@ -198,4 +198,12 @@ public ChoobStatementWrapper(final Statement stat) { @Override public T unwrap(final Class iface) throws SQLException { return stat.unwrap(iface); } + + public void closeOnCompletion() throws SQLException { + throw new SQLException("Method stub; not available in Java 6 and not supported: closeOnCompletion"); + } + + public boolean isCloseOnCompletion() throws SQLException { + return false; + } }