summaryrefslogtreecommitdiff
path: root/jvmfwk/source
diff options
context:
space:
mode:
authorIvo Hinkelmann <ihi@openoffice.org>2009-04-02 16:25:40 +0000
committerIvo Hinkelmann <ihi@openoffice.org>2009-04-02 16:25:40 +0000
commit93350f1c4e7940c400b145403e58070a7d873026 (patch)
treee092953367bd5d4e5c0680ec89865612f4be8ca8 /jvmfwk/source
parent423409561c4cb620eeddbc2c5a42154adbd1bb6f (diff)
CWS-TOOLING: integrate CWS jl119_DEV300
2009-03-13 08:14:58 +0100 jl r269453 : CWS-TOOLING: rebase CWS jl119 to branches/OOO310@269350 (milestone: OOO310:m5) 2009-03-10 16:01:33 +0100 jl r269280 : #i98990# apply patch by jbu: fixing the python script provider 2009-03-10 13:25:02 +0100 jl r269268 : #i93939# 2009-03-10 11:44:07 +0100 jl r269261 : #i93939# 2009-03-09 17:14:58 +0100 jl r269205 : #i93939# choose a different JRE when the selected one was uninstalled 2009-03-09 16:34:34 +0100 jl r269201 : #i93939# choose a different JRE when the selected one was uninstalled 2009-03-05 16:40:16 +0100 jl r268924 : #99618# Do not migrate java settings 2009-02-25 14:29:53 +0100 jl r268439 : #i99618# do not invalidate existing javasettings by using a new date in the update element
Diffstat (limited to 'jvmfwk/source')
-rw-r--r--jvmfwk/source/framework.cxx30
-rw-r--r--jvmfwk/source/framework.map5
2 files changed, 35 insertions, 0 deletions
diff --git a/jvmfwk/source/framework.cxx b/jvmfwk/source/framework.cxx
index 75a20ac98ff3..933e5e10ea09 100644
--- a/jvmfwk/source/framework.cxx
+++ b/jvmfwk/source/framework.cxx
@@ -34,6 +34,7 @@
#include "rtl/ustring.hxx"
#include "rtl/bootstrap.hxx"
#include "osl/thread.hxx"
+#include "osl/file.hxx"
#include "osl/module.hxx"
#include "jvmfwk/framework.h"
#include "jvmfwk/vendorplugin.h"
@@ -1113,6 +1114,35 @@ javaFrameworkError SAL_CALL jfw_getJRELocations(
return errcode;
}
+
+javaFrameworkError jfw_existJRE(const JavaInfo *pInfo, sal_Bool *exist)
+{
+ javaFrameworkError ret = JFW_E_NONE;
+ if (!pInfo || !exist)
+ return JFW_E_INVALID_ARG;
+ ::rtl::OUString sLocation(pInfo->sLocation);
+
+ if (sLocation.getLength() == 0)
+ return JFW_E_INVALID_ARG;
+
+ ::osl::DirectoryItem item;
+ ::osl::File::RC rc_item = ::osl::DirectoryItem::get(sLocation, item);
+ if (::osl::File::E_None == rc_item)
+ {
+ *exist = sal_True;
+ }
+ else if (::osl::File::E_NOENT == rc_item)
+ {
+ *exist = sal_False;
+ }
+ else
+ {
+ ret = JFW_E_ERROR;
+ }
+
+ return ret;
+}
+
void SAL_CALL jfw_lock()
{
jfw::FwkMutex::get().acquire();
diff --git a/jvmfwk/source/framework.map b/jvmfwk/source/framework.map
index 2ce5d22b61dc..c95cc83aa826 100644
--- a/jvmfwk/source/framework.map
+++ b/jvmfwk/source/framework.map
@@ -24,3 +24,8 @@ UDK_3_0_0 {
local:
*;
};
+
+UDK_3.1 { # OOo 3.1.0
+ global:
+ jfw_existJRE;
+} UDK_3_0_0;