diff --git a/build.xml b/build.xml index 7899ee7..6b4cd6b 100644 --- a/build.xml +++ b/build.xml @@ -138,7 +138,7 @@ + deprecation="${compile.deprecation}" source="1.5" target="1.5"> diff --git a/src/com/silverwrist/util/ServletMultipartHandler.java b/src/com/silverwrist/util/ServletMultipartHandler.java index 7c06cfc..0d6197a 100644 --- a/src/com/silverwrist/util/ServletMultipartHandler.java +++ b/src/com/silverwrist/util/ServletMultipartHandler.java @@ -115,6 +115,11 @@ public final class ServletMultipartHandler } // end constructor + public void free() + { + actual_data = null; + } + public long length() { return actual_data.length; @@ -135,6 +140,11 @@ public final class ServletMultipartHandler } // end getBinaryStream + public InputStream getBinaryStream(long pos, long length) + { + return new ByteArrayInputStream(actual_data,(int)pos,(int)length); + } + public long position(byte[] pattern, long start) throws SQLException { logger.warn("position() function is not implemented for MultipartDataValue"); diff --git a/src/com/silverwrist/venice/db/WrappedConnection.java b/src/com/silverwrist/venice/db/WrappedConnection.java index 02a3af0..3c68063 100644 --- a/src/com/silverwrist/venice/db/WrappedConnection.java +++ b/src/com/silverwrist/venice/db/WrappedConnection.java @@ -18,6 +18,7 @@ package com.silverwrist.venice.db; import java.sql.*; +import java.util.Properties; class WrappedConnection implements Connection { @@ -670,6 +671,86 @@ class WrappedConnection implements Connection } // end prepareStatement + public Struct createStruct(String typename, Object[] attributes) throws SQLException + { + return conn.createStruct(typename,attributes); + + } // end createStruct + + public Array createArrayOf(String typename, Object[] elements) throws SQLException + { + return conn.createArrayOf(typename,elements); + + } // end createArrayOf + + public Properties getClientInfo() throws SQLException + { + return conn.getClientInfo(); + + } // end getClientInfo + + public String getClientInfo(String name) throws SQLException + { + return conn.getClientInfo(name); + + } // end getClientInfo + + public void setClientInfo(Properties properties) throws SQLClientInfoException + { + conn.setClientInfo(properties); + + } // end setClientInfo + + public void setClientInfo(String name, String value) throws SQLClientInfoException + { + conn.setClientInfo(name,value); + + } // end setClientInfo + + public boolean isValid(int timeout) throws SQLException + { + return true; + + } // end isValid + + public SQLXML createSQLXML() throws SQLException + { + return conn.createSQLXML(); + + } // end createSQLXML + + public NClob createNClob() throws SQLException + { + return conn.createNClob(); + + } // end createNClob + + public Blob createBlob() throws SQLException + { + return conn.createBlob(); + + } // end createBlob + + public Clob createClob() throws SQLException + { + return conn.createClob(); + + } // end createClob + + public boolean isWrapperFor(Class iface) + { + return (iface==Connection.class); + + } // end isWrapperFor + + public T unwrap(Class iface) throws SQLException + { + if (iface==Connection.class) + return iface.cast(conn); + throw new SQLException("invalid interface"); + + } // end unwrap + /*-------------------------------------------------------------------------------- * External operations *--------------------------------------------------------------------------------