summaryrefslogtreecommitdiff
path: root/filter/qa
diff options
context:
space:
mode:
authorRüdiger Timm <rt@openoffice.org>2004-11-26 13:26:10 +0000
committerRüdiger Timm <rt@openoffice.org>2004-11-26 13:26:10 +0000
commitbd485932c20204bf5a5d7b5ac01a14e1a1bf122b (patch)
tree217786dc97159770d03e71fffbd77a7b7717dfd1 /filter/qa
parentaf68b9d02324bedee24556dc6464fc9ab82ba1fe (diff)
INTEGRATION: CWS recovery04 (1.2.90); FILE MERGED
2004/07/23 13:35:37 hro 1.2.90.1: #i20882# Merging from recovery03
Diffstat (limited to 'filter/qa')
-rw-r--r--filter/qa/complex/filter/detection/typeDetection/Helper.java19
1 files changed, 13 insertions, 6 deletions
diff --git a/filter/qa/complex/filter/detection/typeDetection/Helper.java b/filter/qa/complex/filter/detection/typeDetection/Helper.java
index e05b7c69a248..7b585b41f92f 100644
--- a/filter/qa/complex/filter/detection/typeDetection/Helper.java
+++ b/filter/qa/complex/filter/detection/typeDetection/Helper.java
@@ -2,9 +2,9 @@
*
* $RCSfile: Helper.java,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Date: 2004-01-28 14:58:22 $
+ * last change: $Date: 2004-11-26 14:26:10 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -120,6 +120,7 @@ public class Helper {
m_param = param;
m_log = log;
+
// get all files from the given directory
m_sTestDocPath = (String)param.get("TestDocumentPath");
@@ -226,11 +227,8 @@ public class Helper {
if ( m_param.DebugIsActive ) {
System.out.println("Looking for "+csvFileName);
}
- String PackagePath = this.getClass().getPackage().
- getName().replace('.','/');
- URL url = this.getClass().getResource("/" + PackagePath +
- "/" +csvFileName);
+ URL url = getClassURL(csvFileName);
if (url != null) {
URLConnection connection = url.openConnection();
@@ -456,6 +454,15 @@ public class Helper {
return dummy;
}
+ public URL getClassURL(String fileName){
+ String PackagePath = this.getClass().getPackage().getName().replace('.','/');
+ return this.getClass().getResource("/" + PackagePath +"/" + fileName);
+ }
+
+ public String getClassURLString(String fileName){
+ return getClassURL(fileName).toString().replaceAll("file:","");
+ }
+
}