Author: rob.stryker(a)jboss.com
Date: 2007-09-20 19:47:41 -0400 (Thu, 20 Sep 2007)
New Revision: 3743
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/AbstractJBossLaunchConfigType.java
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/JBossServerStartupLaunchConfiguration.java
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/TwiddleLauncher.java
Log:
removing compiler warnings (generics)
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/AbstractJBossLaunchConfigType.java
===================================================================
---
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/AbstractJBossLaunchConfigType.java 2007-09-20
23:43:34 UTC (rev 3742)
+++
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/AbstractJBossLaunchConfigType.java 2007-09-20
23:47:41 UTC (rev 3743)
@@ -121,11 +121,11 @@
return jbrt;
}
- protected static void addCPEntry(ArrayList list, JBossServer jbs, String relative) {
+ protected static void addCPEntry(ArrayList<IRuntimeClasspathEntry> list,
JBossServer jbs, String relative) {
list.add(JavaRuntime.newArchiveRuntimeClasspathEntry(new
Path(getServerHome(jbs)).append(relative)));
}
- protected static ArrayList convertClasspath(ArrayList cp, IVMInstall vmInstall) {
+ protected static ArrayList<String>
convertClasspath(ArrayList<IRuntimeClasspathEntry> cp, IVMInstall vmInstall) {
if (vmInstall != null) {
try {
cp.add(JavaRuntime.newRuntimeContainerClasspathEntry(
@@ -148,10 +148,10 @@
}
}
- Iterator cpi = cp.iterator();
- ArrayList list = new ArrayList();
+ Iterator<IRuntimeClasspathEntry> cpi = cp.iterator();
+ ArrayList<String> list = new ArrayList<String>();
while (cpi.hasNext()) {
- IRuntimeClasspathEntry entry = (IRuntimeClasspathEntry) cpi.next();
+ IRuntimeClasspathEntry entry = cpi.next();
try {
list.add(entry.getMemento());
} catch (Exception e) {
@@ -163,7 +163,7 @@
return list;
}
- protected static void addDirectory(String serverHome, ArrayList classpath,
+ protected static void addDirectory(String serverHome,
ArrayList<IRuntimeClasspathEntry> classpath,
String dirName) {
String libPath = serverHome + File.separator + dirName;
File libDir = new File(libPath);
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/JBossServerStartupLaunchConfiguration.java
===================================================================
---
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/JBossServerStartupLaunchConfiguration.java 2007-09-20
23:43:34 UTC (rev 3742)
+++
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/JBossServerStartupLaunchConfiguration.java 2007-09-20
23:47:41 UTC (rev 3743)
@@ -36,6 +36,7 @@
import org.eclipse.debug.core.ILaunchManager;
import org.eclipse.debug.core.model.IProcess;
import org.eclipse.jdt.launching.IJavaLaunchConfigurationConstants;
+import org.eclipse.jdt.launching.IRuntimeClasspathEntry;
import org.eclipse.wst.server.core.IServer;
import org.eclipse.wst.server.core.ServerUtil;
import org.eclipse.wst.server.core.internal.ServerType;
@@ -71,15 +72,12 @@
IJBossServerRuntime jbrt = findJBossServerRuntime(server);
String serverHome = getServerHome(jbs);
- ILaunchManager launchManager = DebugPlugin.getDefault().getLaunchManager();
- ILaunchConfigurationType launchConfigType =
launchManager.getLaunchConfigurationType(LAUNCH_TYPE);
-
wc.setAttribute(IJavaLaunchConfigurationConstants.ATTR_PROGRAM_ARGUMENTS,
getDefaultArgs(jbs));
wc.setAttribute(IJavaLaunchConfigurationConstants.ATTR_MAIN_TYPE_NAME,
START_MAIN_TYPE);
wc.setAttribute(IJavaLaunchConfigurationConstants.ATTR_WORKING_DIRECTORY, serverHome +
Path.SEPARATOR + "bin");
- ArrayList classpath = new ArrayList();
+ ArrayList<IRuntimeClasspathEntry> classpath = new
ArrayList<IRuntimeClasspathEntry>();
addCPEntry(classpath, jbs, START_JAR_LOC);
- ArrayList runtimeClassPaths = convertClasspath(classpath, jbrt.getVM());
+ ArrayList<String> runtimeClassPaths = convertClasspath(classpath,
jbrt.getVM());
String cpKey = IJavaLaunchConfigurationConstants.ATTR_CLASSPATH;
wc.setAttribute(cpKey, runtimeClassPaths);
wc.setAttribute(IJavaLaunchConfigurationConstants.ATTR_DEFAULT_CLASSPATH, false);
Modified:
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/TwiddleLauncher.java
===================================================================
---
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/TwiddleLauncher.java 2007-09-20
23:43:34 UTC (rev 3742)
+++
trunk/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/server/internal/launch/TwiddleLauncher.java 2007-09-20
23:47:41 UTC (rev 3743)
@@ -51,7 +51,7 @@
*/
public static ProcessData[] launchTwiddles(String[] twiddleArgs, IServer server, boolean
addPrefix) throws CoreException {
ILaunchConfigurationWorkingCopy wc;
- ArrayList list = new ArrayList();
+ ArrayList<ProcessData> list = new ArrayList<ProcessData>();
for( int i = 0; i < twiddleArgs.length; i++ ) {
String args2 = addPrefix ? TwiddleLaunchConfiguration.getDefaultArgs(server) +
twiddleArgs[i] : twiddleArgs[i];
wc = TwiddleLaunchConfiguration.createLaunchConfiguration(server, args2);