diff options
author | Brian S. O'Neill <bronee@gmail.com> | 2012-05-19 18:22:28 +0000 |
---|---|---|
committer | Brian S. O'Neill <bronee@gmail.com> | 2012-05-19 18:22:28 +0000 |
commit | f27253e0cd590a60de2dc389c89be661d22d0f92 (patch) | |
tree | b93c7ee12ae7719045aad02ba453fed9b186a080 /src/main/java/com/amazon/carbonado/repo | |
parent | 60b4fa0c1cfacc9ad484c08fbbd0de7b69ea27ca (diff) |
Support compilation with JDK 1.7.
Diffstat (limited to 'src/main/java/com/amazon/carbonado/repo')
5 files changed, 48 insertions, 0 deletions
diff --git a/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingCallableStatement.java b/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingCallableStatement.java index c9d258f..dc27b97 100644 --- a/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingCallableStatement.java +++ b/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingCallableStatement.java @@ -638,6 +638,14 @@ class LoggingCallableStatement extends LoggingPreparedStatement implements Calla cs().setNClob(parameterName, reader);
}
+ public <T> T getObject(int parameterIndex, Class<T> type) throws SQLException {
+ return cs().getObject(parameterIndex, type);
+ }
+
+ public <T> T getObject(String parameterName, Class<T> type) throws SQLException {
+ return cs().getObject(parameterName, type);
+ }
+
private CallableStatement cs() {
return (CallableStatement) mStatement;
}
diff --git a/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingConnection.java b/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingConnection.java index c28b70b..ff99184 100644 --- a/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingConnection.java +++ b/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingConnection.java @@ -339,4 +339,26 @@ class LoggingConnection implements Connection { public boolean isWrapperFor(Class<?> iface) throws SQLException {
throw new UnsupportedOperationException();
}
+
+ public void setSchema(String schema) throws SQLException {
+ mCon.setSchema(schema);
+ }
+
+ public String getSchema() throws SQLException {
+ return mCon.getSchema();
+ }
+
+ public void abort(java.util.concurrent.Executor executor) throws SQLException {
+ mCon.abort(executor);
+ }
+
+ public void setNetworkTimeout(java.util.concurrent.Executor executor, int milliseconds)
+ throws SQLException
+ {
+ mCon.setNetworkTimeout(executor, milliseconds);
+ }
+
+ public int getNetworkTimeout() throws SQLException {
+ return mCon.getNetworkTimeout();
+ }
}
diff --git a/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingDataSource.java b/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingDataSource.java index 031e9b2..eb8d5c2 100644 --- a/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingDataSource.java +++ b/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingDataSource.java @@ -20,6 +20,7 @@ package com.amazon.carbonado.repo.jdbc; import java.sql.Connection;
import java.sql.SQLException;
+import java.sql.SQLFeatureNotSupportedException;
import java.io.PrintWriter;
import javax.sql.DataSource;
@@ -115,4 +116,8 @@ public class LoggingDataSource implements DataSource { public boolean isWrapperFor(Class<?> iface) throws SQLException {
throw new UnsupportedOperationException();
}
+
+ public java.util.logging.Logger getParentLogger() throws SQLFeatureNotSupportedException {
+ return mDataSource.getParentLogger();
+ }
}
diff --git a/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingStatement.java b/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingStatement.java index 6f09e0b..cea13f6 100644 --- a/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingStatement.java +++ b/src/main/java/com/amazon/carbonado/repo/jdbc/LoggingStatement.java @@ -232,4 +232,12 @@ class LoggingStatement implements Statement { public boolean isWrapperFor(Class<?> iface) throws SQLException {
throw new UnsupportedOperationException();
}
+
+ public void closeOnCompletion() throws SQLException {
+ mStatement.closeOnCompletion();
+ }
+
+ public boolean isCloseOnCompletion() throws SQLException {
+ return mStatement.isCloseOnCompletion();
+ }
}
diff --git a/src/main/java/com/amazon/carbonado/repo/jdbc/SimpleDataSource.java b/src/main/java/com/amazon/carbonado/repo/jdbc/SimpleDataSource.java index 0352003..9d232c3 100644 --- a/src/main/java/com/amazon/carbonado/repo/jdbc/SimpleDataSource.java +++ b/src/main/java/com/amazon/carbonado/repo/jdbc/SimpleDataSource.java @@ -21,6 +21,7 @@ package com.amazon.carbonado.repo.jdbc; import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
+import java.sql.SQLFeatureNotSupportedException;
import java.io.PrintWriter;
import java.util.Properties;
@@ -151,4 +152,8 @@ public class SimpleDataSource implements DataSource { public boolean isWrapperFor(Class<?> iface) throws SQLException {
throw new UnsupportedOperationException();
}
+
+ public java.util.logging.Logger getParentLogger() throws SQLFeatureNotSupportedException {
+ throw new SQLFeatureNotSupportedException();
+ }
}
|