glenn 02/05/28 18:24:09 Modified: dbcp/src/java/org/apache/commons/dbcp DelegatingCallableStatement.java DelegatingResultSet.java Log: Implemented JDBC 3.0 methods for conditional java 1.4 compile. Now builds using both java 1.3 and java 1.4. Revision Changes Path 1.2 +306 -3 jakarta-commons/dbcp/src/java/org/apache/commons/dbcp/DelegatingCallableStatement.java Index: DelegatingCallableStatement.java =================================================================== RCS file: /home/cvs/jakarta-commons/dbcp/src/java/org/apache/commons/dbcp/DelegatingCallableStatement.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- DelegatingCallableStatement.java 16 May 2002 21:25:37 -0000 1.1 +++ DelegatingCallableStatement.java 29 May 2002 01:24:09 -0000 1.2 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-commons/dbcp/src/java/org/apache/commons/dbcp/DelegatingCallableStatement.java,v 1.1 2002/05/16 21:25:37 glenn Exp $ - * $Revision: 1.1 $ - * $Date: 2002/05/16 21:25:37 $ + * $Header: /home/cvs/jakarta-commons/dbcp/src/java/org/apache/commons/dbcp/DelegatingCallableStatement.java,v 1.2 2002/05/29 01:24:09 glenn Exp $ + * $Revision: 1.2 $ + * $Date: 2002/05/29 01:24:09 $ * * ==================================================================== * @@ -60,6 +60,7 @@ */ package org.apache.commons.dbcp; +import java.net.URL; import java.sql.CallableStatement; import java.math.BigDecimal; import java.sql.Date; @@ -247,4 +248,306 @@ public void addBatch(String sql) throws SQLException { _stmt.addBatch( sql); } public void clearBatch() throws SQLException { _stmt.clearBatch(); } public int[] executeBatch() throws SQLException { return _stmt.executeBatch(); } + + // ------------------- JDBC 3.0 ----------------------------------------- + // Will be uncommented by the build process on a JDBC 3.0 system + +/* JDBC_3_ANT_KEY + + public boolean getMoreResults(int current) throws SQLException { + return _stmt.getMoreResults(current); + } + + public ResultSet getGeneratedKeys() throws SQLException { + return _stmt.getGeneratedKeys(); + } + + public int executeUpdate(String sql, int autoGeneratedKeys) + throws SQLException { + return _stmt.executeUpdate(sql, autoGeneratedKeys); + } + + public int executeUpdate(String sql, int columnIndexes[]) + throws SQLException { + return _stmt.executeUpdate(sql, columnIndexes); + } + + public int executeUpdate(String sql, String columnNames[]) + throws SQLException { + return _stmt.executeUpdate(sql, columnNames); + } + + public boolean execute(String sql, int autoGeneratedKeys) + throws SQLException { + return _stmt.execute(sql, autoGeneratedKeys); + } + + public boolean execute(String sql, int columnIndexes[]) + throws SQLException { + return _stmt.execute(sql, columnIndexes); + } + + public boolean execute(String sql, String columnNames[]) + throws SQLException { + return _stmt.execute(sql, columnNames); + } + + public int getResultSetHoldability() throws SQLException { + return _stmt.getResultSetHoldability(); + } + + public void setURL(int parameterIndex, URL x) throws SQLException { + _stmt.setURL(parameterIndex, x); + } + + public java.sql.ParameterMetaData getParameterMetaData() + throws SQLException { + return _stmt.getParameterMetaData(); + } + + public void registerOutParameter(String parameterName, int sqlType) + throws SQLException { + _stmt.registerOutParameter(parameterName, sqlType); + } + + public void registerOutParameter(String parameterName, + int sqlType, int scale) throws SQLException { + _stmt.registerOutParameter(parameterName, sqlType, scale); + } + + public void registerOutParameter(String parameterName, + int sqlType, String typeName) throws SQLException { + _stmt.registerOutParameter(parameterName, sqlType, typeName); + } + + public URL getURL(int parameterIndex) throws SQLException { + return _stmt.getURL(parameterIndex); + } + + public void setURL(String parameterName, URL val) throws SQLException { + _stmt.setURL(parameterName, val); + } + + public void setNull(String parameterName, int sqlType) + throws SQLException { + _stmt.setNull(parameterName, sqlType); + } + + public void setBoolean(String parameterName, boolean x) + throws SQLException { + _stmt.setBoolean(parameterName, x); + } + + public void setByte(String parameterName, byte x) + throws SQLException { + _stmt.setByte(parameterName, x); + } + + public void setShort(String parameterName, short x) + throws SQLException { + _stmt.setShort(parameterName, x); + } + + public void setInt(String parameterName, int x) + throws SQLException { + _stmt.setInt(parameterName, x); + } + + public void setLong(String parameterName, long x) + throws SQLException { + _stmt.setLong(parameterName, x); + } + + public void setFloat(String parameterName, float x) + throws SQLException { + _stmt.setFloat(parameterName, x); + } + + public void setDouble(String parameterName, double x) + throws SQLException { + _stmt.setDouble(parameterName, x); + } + + public void setBigDecimal(String parameterName, BigDecimal x) + throws SQLException { + _stmt.setBigDecimal(parameterName, x); + } + + public void setString(String parameterName, String x) + throws SQLException { + _stmt.setString(parameterName, x); + } + + public void setBytes(String parameterName, byte [] x) + throws SQLException { + _stmt.setBytes(parameterName, x); + } + + public void setDate(String parameterName, Date x) + throws SQLException { + _stmt.setDate(parameterName, x); + } + + public void setTime(String parameterName, Time x) + throws SQLException { + _stmt.setTime(parameterName, x); + } + + public void setTimestamp(String parameterName, Timestamp x) + throws SQLException { + _stmt.setTimestamp(parameterName, x); + } + + public void setAsciiStream(String parameterName, + InputStream x, int length) + throws SQLException { + _stmt.setAsciiStream(parameterName, x, length); + } + + public void setBinaryStream(String parameterName, + InputStream x, int length) + throws SQLException { + _stmt.setBinaryStream(parameterName, x, length); + } + + public void setObject(String parameterName, + Object x, int targetSqlType, int scale) + throws SQLException { + _stmt.setObject(parameterName, x, targetSqlType, scale); + } + + public void setObject(String parameterName, + Object x, int targetSqlType) + throws SQLException { + _stmt.setObject(parameterName, x, targetSqlType); + } + + public void setObject(String parameterName, Object x) + throws SQLException { + _stmt.setObject(parameterName, x); + } + + public void setCharacterStream(String parameterName, + Reader reader, int length) throws SQLException { + _stmt.setCharacterStream(parameterName, reader, length); + } + + public void setDate(String parameterName, + Date x, Calendar cal) throws SQLException { + _stmt.setDate(parameterName, x, cal); + } + + public void setTime(String parameterName, + Time x, Calendar cal) throws SQLException { + _stmt.setTime(parameterName, x, cal); + } + + public void setTimestamp(String parameterName, + Timestamp x, Calendar cal) throws SQLException { + _stmt.setTimestamp(parameterName, x, cal); + } + + public void setNull(String parameterName, + int sqlType, String typeName) throws SQLException { + _stmt.setNull(parameterName, sqlType, typeName); + } + + public String getString(String parameterName) throws SQLException { + return _stmt.getString(parameterName); + } + + public boolean getBoolean(String parameterName) throws SQLException { + return _stmt.getBoolean(parameterName); + } + + public byte getByte(String parameterName) throws SQLException { + return _stmt.getByte(parameterName); + } + + public short getShort(String parameterName) throws SQLException { + return _stmt.getShort(parameterName); + } + + public int getInt(String parameterName) throws SQLException { + return _stmt.getInt(parameterName); + } + + public long getLong(String parameterName) throws SQLException { + return _stmt.getLong(parameterName); + } + + public float getFloat(String parameterName) throws SQLException { + return _stmt.getFloat(parameterName); + } + + public double getDouble(String parameterName) throws SQLException { + return _stmt.getDouble(parameterName); + } + + public byte [] getBytes(String parameterName) throws SQLException { + return _stmt.getBytes(parameterName); + } + + public Date getDate(String parameterName) throws SQLException { + return _stmt.getDate(parameterName); + } + + public Time getTime(String parameterName) throws SQLException { + return _stmt.getTime(parameterName); + } + + public Timestamp getTimestamp(String parameterName) throws SQLException { + return _stmt.getTimestamp(parameterName); + } + + public Object getObject(String parameterName) throws SQLException { + return _stmt.getObject(parameterName); + } + + public BigDecimal getBigDecimal(String parameterName) throws SQLException { + return _stmt.getBigDecimal(parameterName); + } + + public Object getObject(String parameterName, Map map) + throws SQLException { + return _stmt.getObject(parameterName, map); + } + + public Ref getRef(String parameterName) throws SQLException { + return _stmt.getRef(parameterName); + } + + public Blob getBlob(String parameterName) throws SQLException { + return _stmt.getBlob(parameterName); + } + + public Clob getClob(String parameterName) throws SQLException { + return _stmt.getClob(parameterName); + } + + public Array getArray(String parameterName) throws SQLException { + return _stmt.getArray(parameterName); + } + + public Date getDate(String parameterName, Calendar cal) + throws SQLException { + return _stmt.getDate(parameterName, cal); + } + + public Time getTime(String parameterName, Calendar cal) + throws SQLException { + return _stmt.getTime(parameterName, cal); + } + + public Timestamp getTimestamp(String parameterName, Calendar cal) + throws SQLException { + return _stmt.getTimestamp(parameterName, cal); + } + + public URL getURL(String parameterName) throws SQLException { + return _stmt.getURL(parameterName); + } + +JDBC_3_ANT_KEY */ + } 1.2 +57 -3 jakarta-commons/dbcp/src/java/org/apache/commons/dbcp/DelegatingResultSet.java Index: DelegatingResultSet.java =================================================================== RCS file: /home/cvs/jakarta-commons/dbcp/src/java/org/apache/commons/dbcp/DelegatingResultSet.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- DelegatingResultSet.java 16 May 2002 21:25:37 -0000 1.1 +++ DelegatingResultSet.java 29 May 2002 01:24:09 -0000 1.2 @@ -1,7 +1,7 @@ /* - * $Header: /home/cvs/jakarta-commons/dbcp/src/java/org/apache/commons/dbcp/DelegatingResultSet.java,v 1.1 2002/05/16 21:25:37 glenn Exp $ - * $Revision: 1.1 $ - * $Date: 2002/05/16 21:25:37 $ + * $Header: /home/cvs/jakarta-commons/dbcp/src/java/org/apache/commons/dbcp/DelegatingResultSet.java,v 1.2 2002/05/29 01:24:09 glenn Exp $ + * $Revision: 1.2 $ + * $Date: 2002/05/29 01:24:09 $ * * ==================================================================== * @@ -260,4 +260,58 @@ public Timestamp getTimestamp(int columnIndex, Calendar cal) throws SQLException { return _res.getTimestamp(columnIndex, cal); } public Timestamp getTimestamp(String columnName, Calendar cal) throws SQLException { return _res.getTimestamp(columnName, cal); } + // ------------------- JDBC 3.0 ----------------------------------------- + // Will be uncommented by the build process on a JDBC 3.0 system + +/* JDBC_3_ANT_KEY + + public java.net.URL getURL(int columnIndex) throws SQLException { + return _res.getURL(columnIndex); + } + + public java.net.URL getURL(String columnName) throws SQLException { + return _res.getURL(columnName); + } + + public void updateRef(int columnIndex, java.sql.Ref x) + throws SQLException { + _res.updateRef(columnIndex, x); + } + + public void updateRef(String columnName, java.sql.Ref x) + throws SQLException { + _res.updateRef(columnName, x); + } + + public void updateBlob(int columnIndex, java.sql.Blob x) + throws SQLException { + _res.updateBlob(columnIndex, x); + } + + public void updateBlob(String columnName, java.sql.Blob x) + throws SQLException { + _res.updateBlob(columnName, x); + } + + public void updateClob(int columnIndex, java.sql.Clob x) + throws SQLException { + _res.updateClob(columnIndex, x); + } + + public void updateClob(String columnName, java.sql.Clob x) + throws SQLException { + _res.updateClob(columnName, x); + } + + public void updateArray(int columnIndex, java.sql.Array x) + throws SQLException { + _res.updateArray(columnIndex, x); + } + + public void updateArray(String columnName, java.sql.Array x) + throws SQLException { + _res.updateArray(columnName, x); + } + +JDBC_3_ANT_KEY */ }
-- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>