From 10039462dfebdf6727529ca38b4105fcd7dd5727 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Thu, 18 Dec 2014 11:43:40 +0200 Subject: java: remove more dead code found by looking for unused parameters (in Eclipse) Change-Id: I03cf9bc8312e59747b2d0ac153ee2fc8d76be893 --- connectivity/com/sun/star/sdbcx/comp/hsqldb/StorageFileAccess.java | 4 ++-- connectivity/org/hsqldb/lib/FileSystemRuntimeException.java | 5 +---- connectivity/qa/complex/connectivity/HsqlDriverTest.java | 4 ++-- connectivity/qa/complex/connectivity/hsqldb/TestCacheSize.java | 3 +-- 4 files changed, 6 insertions(+), 10 deletions(-) (limited to 'connectivity') diff --git a/connectivity/com/sun/star/sdbcx/comp/hsqldb/StorageFileAccess.java b/connectivity/com/sun/star/sdbcx/comp/hsqldb/StorageFileAccess.java index 9c184750aa92..3e8a687f1e9f 100644 --- a/connectivity/com/sun/star/sdbcx/comp/hsqldb/StorageFileAccess.java +++ b/connectivity/com/sun/star/sdbcx/comp/hsqldb/StorageFileAccess.java @@ -51,7 +51,7 @@ public class StorageFileAccess implements org.hsqldb.lib.FileAccess{ if ( isStreamElement(key,filename) ) removeElement(key,filename); } catch (java.io.IOException e) { - throw new FileSystemRuntimeException( e, FileSystemRuntimeException.fileAccessRemoveElementFailed ); + throw new FileSystemRuntimeException( e ); } } @@ -62,7 +62,7 @@ public class StorageFileAccess implements org.hsqldb.lib.FileAccess{ renameElement(key,oldName, newName); } } catch (java.io.IOException e) { - throw new FileSystemRuntimeException( e, FileSystemRuntimeException.fileAccessRenameElementFailed ); + throw new FileSystemRuntimeException( e ); } } diff --git a/connectivity/org/hsqldb/lib/FileSystemRuntimeException.java b/connectivity/org/hsqldb/lib/FileSystemRuntimeException.java index 6b3d289a6d4d..b3598ad30af0 100644 --- a/connectivity/org/hsqldb/lib/FileSystemRuntimeException.java +++ b/connectivity/org/hsqldb/lib/FileSystemRuntimeException.java @@ -31,10 +31,7 @@ package org.hsqldb.lib; */ public class FileSystemRuntimeException extends java.lang.RuntimeException { - public static final int fileAccessRemoveElementFailed = 1; - public static final int fileAccessRenameElementFailed = 2; - - public FileSystemRuntimeException(java.lang.Throwable _cause, int _errorCode) { + public FileSystemRuntimeException(java.lang.Throwable _cause) { super(_cause); } diff --git a/connectivity/qa/complex/connectivity/HsqlDriverTest.java b/connectivity/qa/complex/connectivity/HsqlDriverTest.java index 747b2ac870b8..aba01fad939b 100644 --- a/connectivity/qa/complex/connectivity/HsqlDriverTest.java +++ b/connectivity/qa/complex/connectivity/HsqlDriverTest.java @@ -99,7 +99,7 @@ public class HsqlDriverTest extends ComplexTestCase { XDriver drv = UnoRuntime.queryInterface(XDriver.class,param.getMSF().createInstance("com.sun.star.sdbcx.comp.hsqldb.Driver")); - TestCacheSize test = new TestCacheSize((param.getMSF()),info,drv); + TestCacheSize test = new TestCacheSize(info,drv); StopWatch sw = new StopWatch(); @@ -127,7 +127,7 @@ public class HsqlDriverTest extends ComplexTestCase { ,new com.sun.star.beans.PropertyValue("ParameterNameSubstitution",0, false,PropertyState.DIRECT_VALUE) }; XDriver drv = UnoRuntime.queryInterface(XDriver.class,param.getMSF().createInstance("com.sun.star.comp.sdbc.JDBCDriver")); - TestCacheSize test = new TestCacheSize((param.getMSF()),info,drv); + TestCacheSize test = new TestCacheSize(info,drv); test.setURL("jdbc:hsqldb:g:\\hsql\\db"); diff --git a/connectivity/qa/complex/connectivity/hsqldb/TestCacheSize.java b/connectivity/qa/complex/connectivity/hsqldb/TestCacheSize.java index b2b5944f0fa9..d3c802e15a40 100644 --- a/connectivity/qa/complex/connectivity/hsqldb/TestCacheSize.java +++ b/connectivity/qa/complex/connectivity/hsqldb/TestCacheSize.java @@ -39,7 +39,6 @@ package complex.connectivity.hsqldb; import org.hsqldb.lib.StopWatch; import java.util.Random; -import com.sun.star.lang.*; import com.sun.star.uno.UnoRuntime; import com.sun.star.sdbc.*; @@ -111,7 +110,7 @@ public class TestCacheSize { private XDriver drv; private com.sun.star.beans.PropertyValue[] info; - public TestCacheSize(XMultiServiceFactory _xmulti,com.sun.star.beans.PropertyValue[] _info,XDriver _drv){ + public TestCacheSize(com.sun.star.beans.PropertyValue[] _info,XDriver _drv){ drv = _drv; info = _info; } -- cgit