diff options
author | Uwe Stieber | 2013-12-13 14:17:00 +0000 |
---|---|---|
committer | Uwe Stieber | 2013-12-13 14:17:00 +0000 |
commit | ed550c62659324499d41c6fc0785b50106df2cd8 (patch) | |
tree | 6adb9c1ee4edf0db4367110c872161cdb4996713 /target_explorer/plugins/org.eclipse.tcf.te.launch.core/src/org/eclipse/tcf/te | |
parent | c8c7612bb9865c8a41a31a1326d1eefbf82cdb81 (diff) | |
download | org.eclipse.tcf-ed550c62659324499d41c6fc0785b50106df2cd8.tar.gz org.eclipse.tcf-ed550c62659324499d41c6fc0785b50106df2cd8.tar.xz org.eclipse.tcf-ed550c62659324499d41c6fc0785b50106df2cd8.zip |
Target Explorer: Fix Bug 422850 - Target Explorer Build Failures against
Eclipse SDK 4.4m4 Luna
Diffstat (limited to 'target_explorer/plugins/org.eclipse.tcf.te.launch.core/src/org/eclipse/tcf/te')
2 files changed, 14 insertions, 13 deletions
diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.core/src/org/eclipse/tcf/te/launch/core/lm/LaunchConfigHelper.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.core/src/org/eclipse/tcf/te/launch/core/lm/LaunchConfigHelper.java index 20eeabd3f..245676960 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.core/src/org/eclipse/tcf/te/launch/core/lm/LaunchConfigHelper.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.core/src/org/eclipse/tcf/te/launch/core/lm/LaunchConfigHelper.java @@ -38,18 +38,19 @@ public class LaunchConfigHelper { return DebugPlugin.getDefault().getLaunchManager().generateLaunchConfigurationName(name); } - public static void addLaunchConfigAttribute(ILaunchConfigurationWorkingCopy wc, String key, Object value) { + @SuppressWarnings("unchecked") + public static void addLaunchConfigAttribute(ILaunchConfigurationWorkingCopy wc, String key, Object value) { if (value instanceof String) { DefaultPersistenceDelegate.setAttribute(wc, key, (String)value); } else if (value instanceof List) { - DefaultPersistenceDelegate.setAttribute(wc, key, (List<?>)value); + DefaultPersistenceDelegate.setAttribute(wc, key, (List<String>)value); } else if (value instanceof Map) { - DefaultPersistenceDelegate.setAttribute(wc, key, (Map<?,?>)value); + DefaultPersistenceDelegate.setAttribute(wc, key, (Map<String, String>)value); } else if (value instanceof Set) { - DefaultPersistenceDelegate.setAttribute(wc, key, (Set<?>)value); + DefaultPersistenceDelegate.setAttribute(wc, key, (Set<String>)value); } else if (value instanceof Boolean) { DefaultPersistenceDelegate.setAttribute(wc, key, ((Boolean)value).booleanValue()); diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.core/src/org/eclipse/tcf/te/launch/core/persistence/DefaultPersistenceDelegate.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.core/src/org/eclipse/tcf/te/launch/core/persistence/DefaultPersistenceDelegate.java index 8b5454801..d0b522649 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.core/src/org/eclipse/tcf/te/launch/core/persistence/DefaultPersistenceDelegate.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.core/src/org/eclipse/tcf/te/launch/core/persistence/DefaultPersistenceDelegate.java @@ -168,7 +168,7 @@ public class DefaultPersistenceDelegate { * @param attributeId The attribute id to store the attribute value under. Must not be <code>null</code>. * @param attributeValue The attribute value to store under the given attribute id. */ - public final static void setAttribute(ILaunchConfigurationWorkingCopy wc, String attributeId, List<?> attributeValue) { + public final static void setAttribute(ILaunchConfigurationWorkingCopy wc, String attributeId, List<String> attributeValue) { if (wc == null || attributeId == null) return; if (isAttributeChanged(wc, attributeId, attributeValue)) { // Determine the old attribute value @@ -193,7 +193,7 @@ public class DefaultPersistenceDelegate { * @param attributeId The attribute id to store the attribute value under. Must not be <code>null</code>. * @param attributeValue The attribute value to store under the given attribute id. */ - public final static void setAttribute(ILaunchConfigurationWorkingCopy wc, String attributeId, Map<?, ?> attributeValue) { + public final static void setAttribute(ILaunchConfigurationWorkingCopy wc, String attributeId, Map<String, String> attributeValue) { if (wc == null || attributeId == null) return; if (isAttributeChanged(wc, attributeId, attributeValue)) { // Determine the old attribute value @@ -218,7 +218,7 @@ public class DefaultPersistenceDelegate { * @param attributeId The attribute id to store the attribute value under. Must not be <code>null</code>. * @param attributeValue The attribute value to store under the given attribute id. */ - public final static void setAttribute(ILaunchConfigurationWorkingCopy wc, String attributeId, Set<?> attributeValue) { + public final static void setAttribute(ILaunchConfigurationWorkingCopy wc, String attributeId, Set<String> attributeValue) { if (wc == null || attributeId == null) return; if (isAttributeChanged(wc, attributeId, attributeValue)) { // Determine the old attribute value @@ -281,11 +281,11 @@ public class DefaultPersistenceDelegate { * * @return The list attribute or the default value. */ - public final static List<?> getAttribute(ILaunchConfiguration lc, String attributeName, List<?> defaultValue) { + public final static List<String> getAttribute(ILaunchConfiguration lc, String attributeName, List<String> defaultValue) { Assert.isNotNull(lc); Assert.isNotNull(attributeName); - List<?> value = defaultValue; + List<String> value = defaultValue; try { value = lc.getAttribute(attributeName, defaultValue); } catch (CoreException e) { /* ignored on purpose */ } return value; } @@ -300,11 +300,11 @@ public class DefaultPersistenceDelegate { * * @return The set attribute or the default value. */ - public final static Set<?> getAttribute(ILaunchConfiguration lc, String attributeName, Set<?> defaultValue) { + public final static Set<String> getAttribute(ILaunchConfiguration lc, String attributeName, Set<String> defaultValue) { Assert.isNotNull(lc); Assert.isNotNull(attributeName); - Set<?> value = defaultValue; + Set<String> value = defaultValue; try { value = lc.getAttribute(attributeName, defaultValue); } catch (CoreException e) { /* ignored on purpose */ } return value; } @@ -320,11 +320,11 @@ public class DefaultPersistenceDelegate { * * @return The map attribute or the default value. */ - public final static Map<?,?> getAttribute(ILaunchConfiguration lc, String attributeName, Map<?,?> defaultValue) { + public final static Map<String, String> getAttribute(ILaunchConfiguration lc, String attributeName, Map<String, String> defaultValue) { Assert.isNotNull(lc); Assert.isNotNull(attributeName); - Map<?,?> value = defaultValue; + Map<String, String> value = defaultValue; try { value = lc.getAttribute(attributeName, defaultValue); } catch (CoreException e) { /* ignored on purpose */ } return value; } |