Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Rennie2006-10-27 21:35:42 +0000
committerMichael Rennie2006-10-27 21:35:42 +0000
commita9a327c6ad40132450a5ec570c4c80e73683745f (patch)
tree7284f658a27a2434ad9640a58248042c74a12dd5 /org.eclipse.debug.core
parente702bc624ec66bac0b1f2a88e6e8f5e0cc6a2f5d (diff)
downloadeclipse.platform.debug-a9a327c6ad40132450a5ec570c4c80e73683745f.tar.gz
eclipse.platform.debug-a9a327c6ad40132450a5ec570c4c80e73683745f.tar.xz
eclipse.platform.debug-a9a327c6ad40132450a5ec570c4c80e73683745f.zip
updated/reorganized testsuite for contributed delegates, tab contribution, and tab group wrapper
Diffstat (limited to 'org.eclipse.debug.core')
-rw-r--r--org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchDelegate.java28
1 files changed, 13 insertions, 15 deletions
diff --git a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchDelegate.java b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchDelegate.java
index e31bdcd04..aa91f1f9c 100644
--- a/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchDelegate.java
+++ b/org.eclipse.debug.core/core/org/eclipse/debug/internal/core/LaunchDelegate.java
@@ -59,7 +59,6 @@ public final class LaunchDelegate implements ILaunchDelegate {
//a listing of sets of
private List fLaunchModes = null;
- private HashSet fModes = null;
private String fType = null;
/**
@@ -109,22 +108,21 @@ public final class LaunchDelegate implements ILaunchDelegate {
}
/**
- * Parse a list of modes and creates a new set of them
- * @param element the configuraiton element to read from
- * @return a set of launch modes created form a comma seperated list
+ * Simple method to parse mode strings (seperated by commmas)
+ * @param element the config element to read the mode string from
+ * @return a set of the parsed strings or an empty collection
+ * @since 3.3
*/
- private Set getModes(IConfigurationElement element) {
- if (fModes == null) {
- fModes = new HashSet();
- String modes = element.getAttribute(IConfigurationElementConstants.MODES);
- if (modes != null) {
- String[] strings = modes.split(","); //$NON-NLS-1$
- for (int i = 0; i < strings.length; i++) {
- fModes.add(strings[i].trim());
- }
+ private Set parseModes(IConfigurationElement element) {
+ HashSet set = new HashSet();
+ String modes = element.getAttribute(IConfigurationElementConstants.MODES);
+ if (modes != null) {
+ String[] strings = modes.split(","); //$NON-NLS-1$
+ for (int i = 0; i < strings.length; i++) {
+ set.add(strings[i].trim());
}
}
- return fModes;
+ return set;
}
/* (non-Javadoc)
@@ -135,7 +133,7 @@ public final class LaunchDelegate implements ILaunchDelegate {
fLaunchModes = new ArrayList();
IConfigurationElement[] children = fElement.getChildren(IConfigurationElementConstants.MODE_COMBINATION);
for (int i = 0; i < children.length; i++) {
- fLaunchModes.add(getModes(children[i]));
+ fLaunchModes.add(parseModes(children[i]));
}
//try to get the modes from the old definition and make each one
//a seperate set of one element

Back to the top