svn commit: r1814552 [3/6] - in /openoffice/trunk/main: connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/comphelper/ connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/

2017-11-07 Thread damjan
Added: 
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLConnection.java
URL: 
http://svn.apache.org/viewvc/openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLConnection.java?rev=1814552=auto
==
--- 
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLConnection.java
 (added)
+++ 
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLConnection.java
 Wed Nov  8 04:17:25 2017
@@ -0,0 +1,616 @@
+/**
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ */
+package com.sun.star.comp.sdbc;
+
+import java.util.Properties;
+
+import org.apache.openoffice.comp.sdbc.dbtools.util.AutoRetrievingBase;
+import org.apache.openoffice.comp.sdbc.dbtools.util.Resources;
+import org.apache.openoffice.comp.sdbc.dbtools.util.SharedResources;
+import org.apache.openoffice.comp.sdbc.dbtools.util.StandardSQLState;
+
+import com.sun.star.beans.NamedValue;
+import com.sun.star.beans.PropertyValue;
+import com.sun.star.comp.sdbc.ClassMap.ClassLoaderAndClass;
+import com.sun.star.comp.sdbc.ConnectionLog.ObjectType;
+import com.sun.star.container.XNameAccess;
+import com.sun.star.lang.IllegalArgumentException;
+import com.sun.star.lang.XMultiServiceFactory;
+import com.sun.star.lang.XServiceInfo;
+import com.sun.star.lib.uno.helper.ComponentBase;
+import com.sun.star.lib.util.WeakMap;
+import com.sun.star.logging.LogLevel;
+import com.sun.star.sdbc.SQLException;
+import com.sun.star.sdbc.SQLWarning;
+import com.sun.star.sdbc.XConnection;
+import com.sun.star.sdbc.XDatabaseMetaData;
+import com.sun.star.sdbc.XPreparedStatement;
+import com.sun.star.sdbc.XStatement;
+import com.sun.star.sdbc.XWarningsSupplier;
+import com.sun.star.uno.Any;
+import com.sun.star.uno.AnyConverter;
+import com.sun.star.uno.UnoRuntime;
+import com.sun.star.uno.XComponentContext;
+import com.sun.star.util.XStringSubstitution;
+
+public class JavaSQLConnection extends ComponentBase
+implements XConnection, XWarningsSupplier, XServiceInfo {
+
+private static final String[] services = {
+"com.sun.star.sdbc.Connection"
+};
+private static final ClassMap classMap = new ClassMap();
+
+private AutoRetrievingBase autoRetrievingBase = new AutoRetrievingBase();
+private String url;
+private JDBCDriver driver;
+private ConnectionLog logger; 
+private boolean useParameterSubstitution;
+private boolean ignoreDriverPrivileges;
+private boolean ignoreCurrency;
+private Object catalogRestriction;
+private Object schemaRestriction;
+private ClassLoader driverClassLoader;
+private java.sql.Driver driverObject;
+private java.sql.Connection connection;
+private PropertyValue[] connectionInfo;
+private WeakMap statements = new WeakMap();
+
+public JavaSQLConnection(JDBCDriver driver) {
+this.driver = driver;
+this.logger = new ConnectionLog(driver.getLogger(), 
ObjectType.CONNECTION);
+}
+
+// XComponent
+
+@Override
+protected synchronized void postDisposing() {
+logger.log(LogLevel.INFO, Resources.STR_LOG_SHUTDOWN_CONNECTION);
+try {
+if (connection != null) {
+connection.close();
+}
+} catch (java.sql.SQLException sqlException) {
+logger.log(LogLevel.WARNING, sqlException);
+}
+}
+
+// XCloseable
+
+public void close() throws SQLException {
+dispose();
+}
+
+// XServiceInfo
+
+@Override
+public String getImplementationName() {
+return "com.sun.star.sdbcx.JConnection";
+}
+
+@Override
+public String[] getSupportedServiceNames() {
+return services.clone();
+}
+
+@Override
+public boolean supportsService(String serviceName) {
+for (String service : services) {
+if (service.equals(serviceName)) {
+return true;
+}
+}
+

svn commit: r1814552 [1/6] - in /openoffice/trunk/main: connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/comphelper/ connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/

2017-11-07 Thread damjan
Author: damjan
Date: Wed Nov  8 04:17:25 2017
New Revision: 1814552

URL: http://svn.apache.org/viewvc?rev=1814552=rev
Log:
Port our SDBC-JDBC bridge driver to Java. Supported interfaces,
service names, implementation names, logging channels and messages,
initialization arguments, and general behaviour is all preserved, so it
should be completely transparent to client code.

Allow PropertySetAdapter.getPropertyValue() to throw WrappedTargetException,
and PropertySetAdapter.setPropertyValue() to throw PropertyVetoException,
IllegalArgumentException, and WrappedTargetException, as these are
sometimes used to change values in a database driver, which can fail.

Port helper classes from main/comphelper for logging.

Port AutoRetrievingBase.

Add in-memory Column, ResultSet and metadata classes.

Improve handling of Any in ORowSetValue.

Move PostgreSQL's database metadata result set class to dbtools, and
have it only override the method it needs.

It's "information_schema" in PostgreSQL - "INFORMATION_SCHEMA"
doesn't exist and gives an error.

Add a new UNO service com.sun.star.sdb.ParameterSubstitution as was
intended by main/connectivity/source/dbtools/dbtools.component
that allow substituting parameters, so it can be used from Java.

Keep the database drivers in a common install package.

Patch by: me


Added:

openoffice/trunk/main/connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/comphelper/EventLogger.java
   (with props)

openoffice/trunk/main/connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/comphelper/ResourceBasedEventLogger.java
   (with props)

openoffice/trunk/main/connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/util/AutoRetrievingBase.java
   (with props)

openoffice/trunk/main/connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/util/CustomColumn.java
   (with props)

openoffice/trunk/main/connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/util/CustomResultSet.java
   (with props)

openoffice/trunk/main/connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/util/CustomResultSetMetaData.java
   (with props)

openoffice/trunk/main/connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/util/DatabaseMetaDataResultSet.java
  - copied, changed from r1814551, 
openoffice/trunk/main/connectivity/java/sdbc_postgresql/src/com/sun/star/sdbcx/comp/postgresql/DatabaseMetaDataResultSet.java
openoffice/trunk/main/connectivity/java/sdbc_jdbc/
openoffice/trunk/main/connectivity/java/sdbc_jdbc/build.xml   (with props)
openoffice/trunk/main/connectivity/java/sdbc_jdbc/jdbc.component   (with 
props)
openoffice/trunk/main/connectivity/java/sdbc_jdbc/jdbc.xml   (with props)
openoffice/trunk/main/connectivity/java/sdbc_jdbc/makefile.mk
openoffice/trunk/main/connectivity/java/sdbc_jdbc/sdbc_jdbc.xcu   (with 
props)
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/BoundedInputStream.java
   (with props)

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/ClassMap.java
   (with props)

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/ConnectionLog.java
   (with props)

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/ContextClassLoaderScope.java
   (with props)

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JDBCDriver.java
   (with props)

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLArray.java
   (with props)

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLBlob.java
   (with props)

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLCallableStatement.java
   (with props)

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLClob.java
   (with props)

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLConnection.java
   (with props)

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLDatabaseMetaData.java
   (with props)

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLPreparedStatement.java
   (with props)

openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLRef.java
   (with props)


svn commit: r1814552 [2/6] - in /openoffice/trunk/main: connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/comphelper/ connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/

2017-11-07 Thread damjan
Added: openoffice/trunk/main/connectivity/java/sdbc_jdbc/build.xml
URL: 
http://svn.apache.org/viewvc/openoffice/trunk/main/connectivity/java/sdbc_jdbc/build.xml?rev=1814552=auto
==
--- openoffice/trunk/main/connectivity/java/sdbc_jdbc/build.xml (added)
+++ openoffice/trunk/main/connectivity/java/sdbc_jdbc/build.xml Wed Nov  8 
04:17:25 2017
@@ -0,0 +1,250 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+   
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 
+ 
+ 
+ 
+ 
+ 
+ 
+ 
+ 
+ 
+ 
+ 
+ 
+ 
+
+ 
+
+
+
+
+
+   
+
+   
+   
+
+
+
+
+   
+   
+   
+
+
+
+
+
+
+
+
+
+
+
+
+http://java.sun.com/j2se/1.4.2/docs/api;
+  packagelistLoc="${common.doc}/jdk1.4.2"/>
+http://java.sun.com/products/servlet/2.3/javadoc;
+  packagelistLoc="${common.doc}/servlet2.3"/>
+http://logging.apache.org/log4j/docs/api;
+  packagelistLoc="${common.doc}/log4j-1.2.8"/>
+http://java.sun.com/products/javabeans/glasgow/javadocs;
+  packagelistLoc="${common.doc}/jaf-1.0.2"/>
+http://java.sun.com/products/javamail/javadocs;
+  packagelistLoc="${common.doc}/javamail-1.3.1"/>
+http://ws.apache.org/soap/docs;
+  packagelistLoc="${common.doc}/soap-2.3.1"/>
+
+iCopyright #169; 2004 Sun Microsystems, Inc., 
901 San Antonio Road, Palo Alto, CA 94303 USA/i
+${docname}
+
+   
+
+
+
+
+   
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+

Propchange: openoffice/trunk/main/connectivity/java/sdbc_jdbc/build.xml
--
svn:eol-style = native

Propchange: openoffice/trunk/main/connectivity/java/sdbc_jdbc/build.xml
--
svn:mime-type = text/xml

Added: openoffice/trunk/main/connectivity/java/sdbc_jdbc/jdbc.component
URL: 
http://svn.apache.org/viewvc/openoffice/trunk/main/connectivity/java/sdbc_jdbc/jdbc.component?rev=1814552=auto
==
Binary file - no diff available.

Propchange: openoffice/trunk/main/connectivity/java/sdbc_jdbc/jdbc.component
--
svn:mime-type = application/xml

Added: openoffice/trunk/main/connectivity/java/sdbc_jdbc/jdbc.xml
URL: 
http://svn.apache.org/viewvc/openoffice/trunk/main/connectivity/java/sdbc_jdbc/jdbc.xml?rev=1814552=auto
==
--- openoffice/trunk/main/connectivity/java/sdbc_jdbc/jdbc.xml (added)
+++ openoffice/trunk/main/connectivity/java/sdbc_jdbc/jdbc.xml Wed Nov  8 
04:17:25 2017
@@ -0,0 +1,50 @@
+
+
+
+http://www.w3.org/1999/xlink;>
+  jdbc
+   
+   Ocke Janssen
+   com.sun.star.comp.sdbc.JDBCDriver
+   
+   This is the implementation of the sdbc-jdbc bridge.
+   
+   com.sun.star.loader.SharedLibrary
+   c++
+   
+com.sun.star.sdbc.Driver

+   ... 
+ 
+   cppuhelper
+   cppu
+   sal
+   vos
+   cppuhelper
+   cppu
+   sal
+   vos
+   osl
+   dbtools
+   comphelper
+
+
+

Propchange: openoffice/trunk/main/connectivity/java/sdbc_jdbc/jdbc.xml
--
svn:eol-style = native

Propchange: openoffice/trunk/main/connectivity/java/sdbc_jdbc/jdbc.xml

svn commit: r1814552 [4/6] - in /openoffice/trunk/main: connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/comphelper/ connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/

2017-11-07 Thread damjan
Added: 
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLDatabaseMetaData.java
URL: 
http://svn.apache.org/viewvc/openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLDatabaseMetaData.java?rev=1814552=auto
==
--- 
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLDatabaseMetaData.java
 (added)
+++ 
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLDatabaseMetaData.java
 Wed Nov  8 04:17:25 2017
@@ -0,0 +1,1682 @@
+/**
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ */
+package com.sun.star.comp.sdbc;
+
+import java.util.ArrayList;
+import java.util.Map;
+import java.util.TreeMap;
+
+import org.apache.openoffice.comp.sdbc.dbtools.util.CustomColumn;
+import org.apache.openoffice.comp.sdbc.dbtools.util.CustomResultSet;
+import org.apache.openoffice.comp.sdbc.dbtools.util.CustomResultSetMetaData;
+import org.apache.openoffice.comp.sdbc.dbtools.util.ORowSetValue;
+
+import com.sun.star.beans.PropertyValue;
+import com.sun.star.lang.IllegalArgumentException;
+import com.sun.star.lib.uno.helper.WeakBase;
+import com.sun.star.sdbc.ColumnValue;
+import com.sun.star.sdbc.DataType;
+import com.sun.star.sdbc.SQLException;
+import com.sun.star.sdbc.XConnection;
+import com.sun.star.sdbc.XDatabaseMetaData2;
+import com.sun.star.sdbc.XResultSet;
+import com.sun.star.sdbc.XResultSetMetaData;
+import com.sun.star.sdbc.XResultSetMetaDataSupplier;
+import com.sun.star.sdbc.XRow;
+import com.sun.star.uno.AnyConverter;
+import com.sun.star.uno.UnoRuntime;
+
+public class JavaSQLDatabaseMetaData extends WeakBase implements 
XDatabaseMetaData2 {
+private java.sql.DatabaseMetaData jdbcDatabaseMetaData;
+private JavaSQLConnection connection;
+private ConnectionLog logger;
+
+public JavaSQLDatabaseMetaData(java.sql.DatabaseMetaData 
jdbcDatabaseMetaData, JavaSQLConnection connection) {
+this.jdbcDatabaseMetaData = jdbcDatabaseMetaData;
+this.connection = connection;
+this.logger = connection.getLogger();
+}
+
+@Override
+public XConnection getConnection() throws SQLException {
+return connection;
+}
+
+@Override
+public PropertyValue[] getConnectionInfo() {
+return connection.getConnectionInfo();
+}
+
+private XResultSet wrapResultSet(java.sql.ResultSet resultSet) {
+if (resultSet == null) {
+return null;
+}
+return new JavaSQLResultSet(resultSet, connection);
+}
+
+@Override
+public XResultSet getTypeInfo() throws SQLException {
+try {
+return wrapResultSet(jdbcDatabaseMetaData.getTypeInfo());
+} catch (java.sql.SQLException jdbcSQLException) {
+throw Tools.toUnoException(this, jdbcSQLException);
+}
+}
+
+@Override
+public XResultSet getCatalogs() throws SQLException {
+try {
+return wrapResultSet(jdbcDatabaseMetaData.getCatalogs());
+} catch (java.sql.SQLException jdbcSQLException) {
+throw Tools.toUnoException(this, jdbcSQLException);
+}
+}
+
+@Override
+public String getCatalogSeparator() throws SQLException {
+try {
+return jdbcDatabaseMetaData.getCatalogSeparator();
+} catch (java.sql.SQLException jdbcSQLException) {
+throw Tools.toUnoException(this, jdbcSQLException);
+}
+}
+
+@Override
+public XResultSet getSchemas() throws SQLException {
+try {
+return wrapResultSet(jdbcDatabaseMetaData.getCatalogs());
+} catch (java.sql.SQLException jdbcSQLException) {
+throw Tools.toUnoException(this, jdbcSQLException);
+}
+}
+
+@Override
+public XResultSet getColumnPrivileges(Object catalog, String schema, 
String table,
+String columnNamePattern) throws SQLException {
+
+try {
+String jdbcCatalog = null;

svn commit: r1814552 [5/6] - in /openoffice/trunk/main: connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/comphelper/ connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/

2017-11-07 Thread damjan
Added: 
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLResultSet.java
URL: 
http://svn.apache.org/viewvc/openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLResultSet.java?rev=1814552=auto
==
--- 
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLResultSet.java
 (added)
+++ 
openoffice/trunk/main/connectivity/java/sdbc_jdbc/src/com/sun/star/comp/sdbc/JavaSQLResultSet.java
 Wed Nov  8 04:17:25 2017
@@ -0,0 +1,922 @@
+/**
+ * 
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * 
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ * 
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ * 
+ */
+package com.sun.star.comp.sdbc;
+
+import java.io.InputStreamReader;
+import java.math.BigDecimal;
+import java.nio.charset.Charset;
+
+import org.apache.openoffice.comp.sdbc.dbtools.comphelper.PropertySet;
+import 
org.apache.openoffice.comp.sdbc.dbtools.comphelper.PropertySetAdapter.PropertyGetter;
+import 
org.apache.openoffice.comp.sdbc.dbtools.comphelper.PropertySetAdapter.PropertySetter;
+import 
org.apache.openoffice.comp.sdbc.dbtools.comphelper.ResourceBasedEventLogger;
+import org.apache.openoffice.comp.sdbc.dbtools.util.DBTypeConversion;
+import org.apache.openoffice.comp.sdbc.dbtools.util.DbTools;
+import org.apache.openoffice.comp.sdbc.dbtools.util.PropertyIds;
+import org.apache.openoffice.comp.sdbc.dbtools.util.Resources;
+import org.apache.openoffice.comp.sdbc.dbtools.util.SharedResources;
+import org.apache.openoffice.comp.sdbc.dbtools.util.StandardSQLState;
+
+import com.sun.star.beans.PropertyAttribute;
+import com.sun.star.beans.PropertyVetoException;
+import com.sun.star.comp.sdbc.ConnectionLog.ObjectType;
+import com.sun.star.container.XNameAccess;
+import com.sun.star.io.XInputStream;
+import com.sun.star.lang.IllegalArgumentException;
+import com.sun.star.lang.WrappedTargetException;
+import com.sun.star.lang.XServiceInfo;
+import com.sun.star.lib.uno.adapter.InputStreamToXInputStreamAdapter;
+import com.sun.star.lib.uno.adapter.XInputStreamToInputStreamAdapter;
+import com.sun.star.logging.LogLevel;
+import com.sun.star.sdbc.SQLException;
+import com.sun.star.sdbc.SQLWarning;
+import com.sun.star.sdbc.XArray;
+import com.sun.star.sdbc.XBlob;
+import com.sun.star.sdbc.XClob;
+import com.sun.star.sdbc.XCloseable;
+import com.sun.star.sdbc.XColumnLocate;
+import com.sun.star.sdbc.XRef;
+import com.sun.star.sdbc.XResultSet;
+import com.sun.star.sdbc.XResultSetMetaData;
+import com.sun.star.sdbc.XResultSetMetaDataSupplier;
+import com.sun.star.sdbc.XResultSetUpdate;
+import com.sun.star.sdbc.XRow;
+import com.sun.star.sdbc.XRowUpdate;
+import com.sun.star.sdbc.XWarningsSupplier;
+import com.sun.star.uno.Any;
+import com.sun.star.uno.AnyConverter;
+import com.sun.star.uno.Type;
+import com.sun.star.util.Date;
+import com.sun.star.util.DateTime;
+import com.sun.star.util.Time;
+
+public class JavaSQLResultSet extends PropertySet
+implements XResultSet, XRow, XResultSetMetaDataSupplier,
+XWarningsSupplier, XResultSetUpdate, XRowUpdate, XCloseable,
+XColumnLocate, XServiceInfo {
+
+private static final String[] services = {
+"com.sun.star.sdbc.ResultSet"
+};
+
+private java.sql.ResultSet jdbcResultSet;
+private JavaSQLConnection connection;
+private Object statement;
+private ResourceBasedEventLogger logger;
+
+public JavaSQLResultSet(java.sql.ResultSet jdbcResultSet, 
JavaSQLConnection connection) {
+this (jdbcResultSet, connection, null);
+}
+
+public JavaSQLResultSet(java.sql.ResultSet jdbcResultSet, 
JavaSQLConnection connection, Object statement) {
+this.jdbcResultSet = jdbcResultSet;
+this.connection = connection;
+this.statement = statement;
+logger = new ConnectionLog(connection.getLogger(), ObjectType.RESULT);
+registerProperties();
+}
+
+// XComponent
+
+@Override
+protected synchronized void postDisposing() {
+super.postDisposing();
+if (jdbcResultSet != null) {
+

svn commit: r1814552 [6/6] - in /openoffice/trunk/main: connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/dbtools/comphelper/ connectivity/java/dbtools/src/org/apache/openoffice/comp/sdbc/

2017-11-07 Thread damjan
Modified: openoffice/trunk/main/scp2/source/ooo/file_library_ooo.scp
URL: 
http://svn.apache.org/viewvc/openoffice/trunk/main/scp2/source/ooo/file_library_ooo.scp?rev=1814552=1814551=1814552=diff
==
--- openoffice/trunk/main/scp2/source/ooo/file_library_ooo.scp (original)
+++ openoffice/trunk/main/scp2/source/ooo/file_library_ooo.scp Wed Nov  8 
04:17:25 2017
@@ -796,7 +796,12 @@ End
 
 #ifdef SOLAR_JAVA
 
-STD_LIB_FILE( gid_File_Lib_Jdbc, jdbc)
+#ifndef SYSTEM_APACHE_COMMONS
+STD_JAR_FILE( gid_File_Jar_Apache_Commons_Lang, commons-lang3-3.3 )
+#endif
+STD_JAR_FILE( gid_File_Jar_DbTools_Sdbc, dbtools )
+STD_JAR_FILE( gid_File_Jar_Jdbc_Sdbc, sdbc_jdbc )
+STD_JAR_FILE( gid_File_Jar_PostgreSQL_Sdbc, sdbc_postgresql )
 
 #endif
 

Modified: openoffice/trunk/main/scp2/source/ooo/file_ooo.scp
URL: 
http://svn.apache.org/viewvc/openoffice/trunk/main/scp2/source/ooo/file_ooo.scp?rev=1814552=1814551=1814552=diff
==
--- openoffice/trunk/main/scp2/source/ooo/file_ooo.scp (original)
+++ openoffice/trunk/main/scp2/source/ooo/file_ooo.scp Wed Nov  8 04:17:25 2017
@@ -429,14 +429,6 @@ STD_JAR_FILE( gid_File_Jar_Hsqldb_Sdbc,
 #endif
 
 #ifdef SOLAR_JAVA
-#ifndef SYSTEM_APACHE_COMMONS
-STD_JAR_FILE( gid_File_Jar_Apache_Commons_Lang, commons-lang3-3.3 )
-#endif
-STD_JAR_FILE( gid_File_Jar_DbTools_Sdbc, dbtools )
-STD_JAR_FILE( gid_File_Jar_PostgreSQL_Sdbc, sdbc_postgresql )
-#endif
-
-#ifdef SOLAR_JAVA
 File gid_File_Jar_Commonwizards
 TXT_FILE_BODY;
 Name = JARFILENAME(commonwizards);

Modified: openoffice/trunk/main/scp2/source/ooo/module_hidden_ooo.scp
URL: 
http://svn.apache.org/viewvc/openoffice/trunk/main/scp2/source/ooo/module_hidden_ooo.scp?rev=1814552=1814551=1814552=diff
==
--- openoffice/trunk/main/scp2/source/ooo/module_hidden_ooo.scp (original)
+++ openoffice/trunk/main/scp2/source/ooo/module_hidden_ooo.scp Wed Nov  8 
04:17:25 2017
@@ -88,6 +88,7 @@ Module gid_Module_Root_Files_3
gid_File_Jar_Hsqldb_Sdbc,
gid_File_Jar_Apache_Commons_Lang,
gid_File_Jar_DbTools_Sdbc,
+   gid_File_Jar_Jdbc_Sdbc,
gid_File_Jar_PostgreSQL_Sdbc,
gid_File_Jar_Accessbridge,
gid_File_Jar_Js,
@@ -326,7 +327,6 @@ Module gid_Module_Root_Files_5
gid_File_Lib_Localedata_Euro,
gid_File_Lib_Localedata_Others,
gid_File_Lib_Hsqldb_2,
-   gid_File_Lib_Jdbc,
gid_File_Lib_Mcnttype,
gid_File_Lib_Mysql,
gid_File_Lib_Odbc,