Author: rob.stryker(a)jboss.com
Date: 2011-08-02 02:16:44 -0400 (Tue, 02 Aug 2011)
New Revision: 33436
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/configuration/LocalJBossStartLaunchConfigurator.java
Log:
JBIDE-9439 - snjezana's patch
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/configuration/LocalJBossStartLaunchConfigurator.java
===================================================================
---
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/configuration/LocalJBossStartLaunchConfigurator.java 2011-08-02
02:36:55 UTC (rev 33435)
+++
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/configuration/LocalJBossStartLaunchConfigurator.java 2011-08-02
06:16:44 UTC (rev 33436)
@@ -11,10 +11,13 @@
package org.jboss.ide.eclipse.as.core.server.internal.launch.configuration;
import java.net.MalformedURLException;
+import java.util.ArrayList;
import java.util.List;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.launching.IRuntimeClasspathEntry;
+import org.eclipse.jdt.launching.IVMInstall;
import org.eclipse.wst.server.core.IServer;
import org.jboss.ide.eclipse.as.core.server.IJBossServerRuntime;
import org.jboss.ide.eclipse.as.core.server.internal.JBossServer;
@@ -50,6 +53,16 @@
String runJarEntry =
LaunchConfigUtils.getRunJarRuntimeCPEntry(server.getServer()).getMemento();
currentClasspath.add(runJarEntry);
}
+ IVMInstall vmInstall = runtime.getVM();
+ List<IRuntimeClasspathEntry> classpath = new
ArrayList<IRuntimeClasspathEntry>();
+ LaunchConfigUtils.addJREEntry(vmInstall, classpath);
+ List<String> runtimeClassPaths = LaunchConfigUtils.toStrings(classpath);
+ if (runtimeClassPaths != null && runtimeClassPaths.size() == 1) {
+ String jreEntry = runtimeClassPaths.get(0);
+ if (!currentClasspath.contains(jreEntry)) {
+ currentClasspath.add(jreEntry);
+ }
+ }
return currentClasspath;
} catch (CoreException ce) {
return currentClasspath;
Show replies by date