diff options
author | Pascal Rapicault | 2013-01-21 16:34:38 +0000 |
---|---|---|
committer | Pascal Rapicault | 2013-01-21 16:34:38 +0000 |
commit | dfec14b67a69b6fa14efb860ef8a986053a58917 (patch) | |
tree | 7f77c6feb9c5549ffa55adce8eee34ee62cf0d81 /bundles | |
parent | 6067d05e402fe796debd9d25604cae7026df5b48 (diff) | |
parent | ba5f048a3ac5563430104adeb173dc4f7dda6eca (diff) | |
download | rt.equinox.p2-dfec14b.tar.gz rt.equinox.p2-dfec14b.tar.xz rt.equinox.p2-dfec14b.zip |
Merge branch 'master' into prapicau/sharedInstall-part1
Diffstat (limited to 'bundles')
61 files changed, 1184 insertions, 619 deletions
diff --git a/bundles/org.eclipse.equinox.frameworkadmin.equinox/pom.xml b/bundles/org.eclipse.equinox.frameworkadmin.equinox/pom.xml index 0ba20869d..ab057aff2 100644 --- a/bundles/org.eclipse.equinox.frameworkadmin.equinox/pom.xml +++ b/bundles/org.eclipse.equinox.frameworkadmin.equinox/pom.xml @@ -12,4 +12,28 @@ <artifactId>org.eclipse.equinox.frameworkadmin.equinox</artifactId> <version>1.0.500-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> + + <profiles> + <profile> + <id>bree-libs</id> + <build> + <plugins> + <plugin> + <groupId>org.eclipse.tycho</groupId> + <artifactId>target-platform-configuration</artifactId> + <configuration> + <executionEnvironment>CDC-1.1/Foundation-1.1</executionEnvironment> + </configuration> + </plugin> + <plugin> + <groupId>org.eclipse.tycho</groupId> + <artifactId>tycho-compiler-plugin</artifactId> + <configuration> + <useJDK>BREE</useJDK> + </configuration> + </plugin> + </plugins> + </build> + </profile> + </profiles> </project> diff --git a/bundles/org.eclipse.equinox.p2.core/.settings/org.eclipse.pde.api.tools.prefs b/bundles/org.eclipse.equinox.p2.core/.settings/org.eclipse.pde.api.tools.prefs deleted file mode 100644 index 7b4e4a2c4..000000000 --- a/bundles/org.eclipse.equinox.p2.core/.settings/org.eclipse.pde.api.tools.prefs +++ /dev/null @@ -1,88 +0,0 @@ -#Wed Dec 03 12:05:24 EST 2008 -ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error -ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error -ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error -ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error -ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error -API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error -API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error -CLASS_ELEMENT_TYPE_ADDED_METHOD=Error -CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error -CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error -CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error -CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error -CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error -CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error -CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error -CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error -CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error -CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error -CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error -CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error -CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error -CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error -CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error -CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error -CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error -ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error -ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error -ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error -ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error -ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error -ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error -FIELD_ELEMENT_TYPE_ADDED_VALUE=Error -FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error -FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error -FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error -FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error -FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error -FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error -FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error -FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error -FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error -ILLEGAL_EXTEND=Warning -ILLEGAL_IMPLEMENT=Warning -ILLEGAL_INSTANTIATE=Warning -ILLEGAL_OVERRIDE=Warning -ILLEGAL_REFERENCE=Warning -INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Warning -INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error -INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error -INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error -INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error -INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error -INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error -INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error -INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error -INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error -INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error -INVALID_JAVADOC_TAG=Warning -INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Error -LEAK_EXTEND=Warning -LEAK_FIELD_DECL=Warning -LEAK_IMPLEMENT=Warning -LEAK_METHOD_PARAM=Warning -LEAK_METHOD_RETURN_TYPE=Warning -METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error -METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error -METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error -METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error -METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error -METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error -METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error -METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error -METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error -METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error -TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error -TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error -TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error -TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error -TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error -TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error -eclipse.preferences.version=1 -incompatible_api_component_version=Error -incompatible_api_component_version_include_major_without_breaking_change=Disabled -incompatible_api_component_version_include_minor_without_api_change=Disabled -invalid_since_tag_version=Error -malformed_since_tag=Error -missing_since_tag=Error diff --git a/bundles/org.eclipse.equinox.p2.core/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.p2.core/META-INF/MANIFEST.MF index 25510729b..51772cfd3 100644 --- a/bundles/org.eclipse.equinox.p2.core/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.equinox.p2.core/META-INF/MANIFEST.MF @@ -66,7 +66,6 @@ Export-Package: org.eclipse.equinox.internal.p2.core;x-friends:="org.eclipse.equ org.eclipse.equinox.p2.core.spi;version="2.1.0" Require-Bundle: org.eclipse.equinox.common;bundle-version="[3.5.0,4.0.0)" Bundle-RequiredExecutionEnvironment: J2SE-1.5, - J2SE-1.4, CDC-1.1/Foundation-1.1 Bundle-ActivationPolicy: lazy Service-Component: OSGI-INF/eventBus.xml, OSGI-INF/agentProvider.xml diff --git a/bundles/org.eclipse.equinox.p2.core/src/org/eclipse/equinox/p2/core/IProvisioningAgent.java b/bundles/org.eclipse.equinox.p2.core/src/org/eclipse/equinox/p2/core/IProvisioningAgent.java index 53abedc3c..22f506b47 100644 --- a/bundles/org.eclipse.equinox.p2.core/src/org/eclipse/equinox/p2/core/IProvisioningAgent.java +++ b/bundles/org.eclipse.equinox.p2.core/src/org/eclipse/equinox/p2/core/IProvisioningAgent.java @@ -42,11 +42,13 @@ public interface IProvisioningAgent { /** * When running in "shared mode", this allows to retrieve from the IProvisioningAgent the agent representing what is in the shared location aka the base + * @since 2.3 */ public static final String SHARED_BASE_AGENT = "org.eclipse.equinox.shared.base.agent"; //$NON-NLS-1$ /** * When running in "shared mode", this allows to retrieve from the IProvisioningAgent identified by {@link #SHARED_BASE_AGENT} the current agent + * @since 2.3 */ public static final String SHARED_CURRENT_AGENT = "org.eclipse.equinox.shared.current.agent"; //$NON-NLS-1$ /** diff --git a/bundles/org.eclipse.equinox.p2.director/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.p2.director/META-INF/MANIFEST.MF index 5bea11eec..f9ad8f358 100644 --- a/bundles/org.eclipse.equinox.p2.director/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.equinox.p2.director/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: %pluginName Bundle-SymbolicName: org.eclipse.equinox.p2.director;singleton:=true -Bundle-Version: 2.2.0.qualifier +Bundle-Version: 2.3.0.qualifier Bundle-ClassPath: . Bundle-Activator: org.eclipse.equinox.internal.p2.director.DirectorActivator Bundle-Vendor: %providerName diff --git a/bundles/org.eclipse.equinox.p2.director/pom.xml b/bundles/org.eclipse.equinox.p2.director/pom.xml index ab76fa976..d9bf222e5 100644 --- a/bundles/org.eclipse.equinox.p2.director/pom.xml +++ b/bundles/org.eclipse.equinox.p2.director/pom.xml @@ -10,6 +10,6 @@ </parent> <groupId>org.eclipse</groupId> <artifactId>org.eclipse.equinox.p2.director</artifactId> - <version>2.2.0-SNAPSHOT</version> + <version>2.3.0-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> </project> diff --git a/bundles/org.eclipse.equinox.p2.discovery.compatibility/pom.xml b/bundles/org.eclipse.equinox.p2.discovery.compatibility/pom.xml index 6e82420de..781cbc107 100644 --- a/bundles/org.eclipse.equinox.p2.discovery.compatibility/pom.xml +++ b/bundles/org.eclipse.equinox.p2.discovery.compatibility/pom.xml @@ -23,4 +23,15 @@ <artifactId>org.eclipse.equinox.p2.discovery.compatibility</artifactId> <version>1.0.101-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> + <build> + <plugins> + <plugin> + <groupId>org.eclipse.tycho</groupId> + <artifactId>target-platform-configuration</artifactId> + <configuration> + <executionEnvironment>J2SE-1.5</executionEnvironment> + </configuration> + </plugin> + </plugins> + </build> </project> diff --git a/bundles/org.eclipse.equinox.p2.discovery/pom.xml b/bundles/org.eclipse.equinox.p2.discovery/pom.xml index be68851e4..9f6096a96 100644 --- a/bundles/org.eclipse.equinox.p2.discovery/pom.xml +++ b/bundles/org.eclipse.equinox.p2.discovery/pom.xml @@ -12,4 +12,15 @@ <artifactId>org.eclipse.equinox.p2.discovery</artifactId> <version>1.0.200-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> + <build> + <plugins> + <plugin> + <groupId>org.eclipse.tycho</groupId> + <artifactId>target-platform-configuration</artifactId> + <configuration> + <executionEnvironment>J2SE-1.5</executionEnvironment> + </configuration> + </plugin> + </plugins> + </build> </project> diff --git a/bundles/org.eclipse.equinox.p2.engine/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.p2.engine/META-INF/MANIFEST.MF index 560e130d0..5f5fa2a70 100644 --- a/bundles/org.eclipse.equinox.p2.engine/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.equinox.p2.engine/META-INF/MANIFEST.MF @@ -48,7 +48,6 @@ Import-Package: javax.xml.parsers, org.eclipse.equinox.p2.repository.metadata;version="[2.0.0,3.0.0)", org.eclipse.equinox.p2.repository.metadata.spi;version="[2.0.0,3.0.0)", org.eclipse.equinox.p2.repository.spi;version="2.0.0", - org.eclipse.equinox.security.storage;version="1.0.0", org.eclipse.osgi.service.datalocation;version="1.0.0", org.eclipse.osgi.service.debug;version="1.1.0", org.eclipse.osgi.service.security;version="1.0.0", diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/AssignVariableAction.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/AssignVariableAction.java new file mode 100644 index 000000000..bcadf35f0 --- /dev/null +++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/AssignVariableAction.java @@ -0,0 +1,21 @@ +package org.eclipse.equinox.internal.p2.engine; + +import java.util.Map; +import org.eclipse.core.runtime.IStatus; +import org.eclipse.equinox.p2.engine.spi.ProvisioningAction; + +public class AssignVariableAction extends ProvisioningAction { + + @Override + public IStatus execute(Map<String, Object> parameters) { + // TODO Auto-generated method stub + return null; + } + + @Override + public IStatus undo(Map<String, Object> parameters) { + // TODO Auto-generated method stub + return null; + } + +} diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/EngineSession.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/EngineSession.java index f61905e3f..cdf1e618a 100644 --- a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/EngineSession.java +++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/EngineSession.java @@ -149,10 +149,11 @@ public class EngineSession { monitor.subTask(Messages.rollingback_error); MultiStatus status = new MultiStatus(EngineActivator.ID, IStatus.OK, null, null); + SubMonitor sub = SubMonitor.convert(monitor, 100 * (phaseActionRecordsPairs.size() + (currentPhaseActive ? 1 : 0) + 1 /* for touchpoint */)); if (currentPhaseActive) { try { - IStatus result = rollBackPhase(currentPhase, currentActionRecords); + IStatus result = rollBackPhase(currentPhase, currentActionRecords, sub.newChild(100)); if (!result.isOK()) status.add(result); } catch (RuntimeException e) { @@ -175,7 +176,7 @@ public class EngineSession { @SuppressWarnings("unchecked") List<ActionsRecord> actionRecords = (List<ActionsRecord>) pair[1]; try { - final IStatus result = rollBackPhase(phase, actionRecords); + final IStatus result = rollBackPhase(phase, actionRecords, sub.newChild(100)); if (!result.isOK()) status.add(result); } catch (RuntimeException e) { @@ -189,6 +190,7 @@ public class EngineSession { } phaseActionRecordsPairs.clear(); + SubMonitor touchpointSub = sub.setWorkRemaining(100).newChild(100).setWorkRemaining(touchpoints.size() + 1); for (Touchpoint touchpoint : touchpoints) { try { IStatus result = touchpoint.rollback(profile); @@ -201,24 +203,31 @@ public class EngineSession { } catch (LinkageError e) { // Catch linkage errors as these are generally recoverable but let other Errors propagate (see bug 222001) status.add(new Status(IStatus.ERROR, EngineActivator.ID, NLS.bind(Messages.touchpoint_rollback_error, touchpoint.getClass().getName()), e)); + } finally { + touchpointSub.worked(1); } } - if (status.matches(IStatus.ERROR)) { - MultiStatus result = new MultiStatus(EngineActivator.ID, IStatus.ERROR, NLS.bind(Messages.session_commit_error, profile.getProfileId()), null); - result.merge(status); - return result; + try { + if (status.matches(IStatus.ERROR)) { + MultiStatus result = new MultiStatus(EngineActivator.ID, IStatus.ERROR, NLS.bind(Messages.session_commit_error, profile.getProfileId()), null); + result.merge(status); + return result; + } + return status; + } finally { + touchpointSub.worked(1); } - return status; } - private IStatus rollBackPhase(Phase phase, List<ActionsRecord> actionRecords) { + private IStatus rollBackPhase(Phase phase, List<ActionsRecord> actionRecords, IProgressMonitor monitor) { MultiStatus result = new MultiStatus(EngineActivator.ID, IStatus.OK, null, null); + SubMonitor sub = SubMonitor.convert(monitor, 10 + 10 + 10 * actionRecords.size()); try { phase.actionManager = (ActionManager) agent.getService(ActionManager.SERVICE_NAME); if (!currentPhaseActive) - phase.prePerform(result, this, new NullProgressMonitor()); + phase.prePerform(result, this, sub.newChild(10)); for (ListIterator<ActionsRecord> it = actionRecords.listIterator(actionRecords.size()); it.hasPrevious();) { ActionsRecord record = it.previous(); @@ -234,9 +243,11 @@ public class EngineSession { } catch (LinkageError e) { // Catch linkage errors as these are generally recoverable but let other Errors propagate (see bug 222001) result.add(new Status(IStatus.ERROR, EngineActivator.ID, NLS.bind(Messages.phase_undo_operand_error, phase.getClass().getName(), record.operand), e)); + } finally { + sub.worked(10); } } - phase.postPerform(result, this, new NullProgressMonitor()); + phase.postPerform(result, this, sub.setWorkRemaining(10).newChild(10)); } finally { phase.actionManager = null; } diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ParameterizedProvisioningAction.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ParameterizedProvisioningAction.java index 8437cb324..2ab439531 100644 --- a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ParameterizedProvisioningAction.java +++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ParameterizedProvisioningAction.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2005, 2010 IBM Corporation and others. + * Copyright (c) 2005, 2012 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -7,19 +7,21 @@ * * Contributors: * IBM Corporation - initial API and implementation + * Landmark Graphics Corporation - bug 397183 *******************************************************************************/ package org.eclipse.equinox.internal.p2.engine; import java.util.*; import java.util.Map.Entry; import org.eclipse.core.runtime.IStatus; -import org.eclipse.equinox.p2.engine.spi.ProvisioningAction; -import org.eclipse.equinox.p2.engine.spi.Touchpoint; +import org.eclipse.equinox.p2.engine.spi.*; public class ParameterizedProvisioningAction extends ProvisioningAction { - private ProvisioningAction action; private Map<String, String> actionParameters; + //ActualParameter is used to keep values to which variables have been resolved. + //This is especially useful when undoing in the presence of variables that change (e.g. lastResult) + private Map<String, Object> actualParameters; private String actionText; public ParameterizedProvisioningAction(ProvisioningAction action, Map<String, String> actionParameters, String actionText) { @@ -27,6 +29,7 @@ public class ParameterizedProvisioningAction extends ProvisioningAction { throw new IllegalArgumentException(Messages.ParameterizedProvisioningAction_action_or_parameters_null); this.action = action; this.actionParameters = actionParameters; + this.actualParameters = new HashMap<String, Object>(actionParameters.size()); this.actionText = actionText; } @@ -44,14 +47,14 @@ public class ParameterizedProvisioningAction extends ProvisioningAction { Map<String, Object> result = new HashMap<String, Object>(parameters); for (Entry<String, String> entry : actionParameters.entrySet()) { String name = entry.getKey(); - String value = processVariables(entry.getValue(), parameters); + Object value = processVariables(entry.getValue(), parameters, false); result.put(name, value); } return Collections.unmodifiableMap(result); } - private String processVariables(String parameterValue, Map<String, Object> parameters) { - + //allowInfixReplacement triggers the replacement of the variables found in the middle of a string (e.g. abc${var}def) + private Object processVariables(String parameterValue, Map<String, Object> parameters, boolean allowInfixReplacement) { int variableBeginIndex = parameterValue.indexOf("${"); //$NON-NLS-1$ if (variableBeginIndex == -1) return parameterValue; @@ -62,7 +65,26 @@ public class ParameterizedProvisioningAction extends ProvisioningAction { String preVariable = parameterValue.substring(0, variableBeginIndex); String variableName = parameterValue.substring(variableBeginIndex + 2, variableEndIndex); - Object value = parameters.get(variableName); + + //replace the internal name by the user visible name + if (Phase.LAST_RESULT_PUBLIC_NAME.equals(variableName)) { + variableName = Phase.LAST_RESULT_INTERNAL_NAME; + } + Object valueUsed = actualParameters.get(variableName); + Object value = valueUsed == null ? parameters.get(variableName) : valueUsed; + actualParameters.put(variableName, value); + + if (value instanceof Value) { + if (allowInfixReplacement == false && variableBeginIndex == 0 && variableEndIndex == parameterValue.length() - 1) { + return ((Value<?>) value).getValue(); + } + + Value<?> result = (Value<?>) value; + if (result.getClazz() == String.class) { + value = result.getValue(); + } else + throw new RuntimeException("The type of the variable is expected to be a String"); //$NON-NLS-1$ + } // try to replace this parameter with a character if (value == null && variableName.charAt(0) == '#') { @@ -75,8 +97,8 @@ public class ParameterizedProvisioningAction extends ProvisioningAction { } } - String variableValue = value == null ? "" : value.toString(); //$NON-NLS-1$ - String postVariable = processVariables(parameterValue.substring(variableEndIndex + 1), parameters); + String variableValue = value == null ? "" : value.toString(); //$NON-NLS-1$ //TODO This is where we replace the values + String postVariable = (String) processVariables(parameterValue.substring(variableEndIndex + 1), parameters, true); return preVariable + variableValue + postVariable; } @@ -99,4 +121,10 @@ public class ParameterizedProvisioningAction extends ProvisioningAction { public void setTouchpoint(Touchpoint touchpoint) { throw new UnsupportedOperationException(); } + + @Override + public Value<?> getResult() { + return action.getResult(); + } + } diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/Phase.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/Phase.java index bcf912978..a981318e9 100644 --- a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/Phase.java +++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/Phase.java @@ -7,6 +7,7 @@ * * Contributors: * IBM Corporation - initial API and implementation + * Landmark Graphics Corporation - bug 397183 *******************************************************************************/ package org.eclipse.equinox.internal.p2.engine; @@ -32,6 +33,8 @@ public abstract class Phase { protected static final String PARM_AGENT = "agent"; //$NON-NLS-1$ protected static final String PARM_FORCED = "forced"; //$NON-NLS-1$ protected static final String PARM_TOUCHPOINT = "touchpoint"; //$NON-NLS-1$ + protected static final String LAST_RESULT_INTERNAL_NAME = "_p2_internal_last_result_variable_"; //$NON-NLS-1$ // + protected static final String LAST_RESULT_PUBLIC_NAME = "lastResult"; //$NON-NLS-1$ protected final String phaseId; protected final int weight; @@ -155,8 +158,8 @@ public abstract class Phase { operandParameters = touchpointToTouchpointOperandParameters.get(operandTouchpoint); } - operandParameters = Collections.unmodifiableMap(operandParameters); if (actions != null) { + Object lastResult = null; for (int j = 0; j < actions.size(); j++) { ProvisioningAction action = actions.get(j); Map<String, Object> parameters = operandParameters; @@ -168,10 +171,17 @@ public abstract class Phase { parameters = touchpointToTouchpointOperandParameters.get(touchpoint); } + if (lastResult != null) { + parameters = new HashMap<String, Object>(parameters); + parameters.put(LAST_RESULT_INTERNAL_NAME, lastResult); + } + parameters = Collections.unmodifiableMap(parameters); + IStatus actionStatus = null; try { session.recordActionExecute(action, parameters); actionStatus = action.execute(parameters); + lastResult = action.getResult(); } catch (RuntimeException e) { if (!forced) throw e; diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ProfilePreferences.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ProfilePreferences.java index 01b9aa7ec..d62eb97e5 100644 --- a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ProfilePreferences.java +++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/ProfilePreferences.java @@ -22,7 +22,6 @@ import org.eclipse.equinox.internal.p2.core.helpers.Tracing; import org.eclipse.equinox.p2.core.IAgentLocation; import org.eclipse.equinox.p2.core.IProvisioningAgent; import org.eclipse.equinox.p2.engine.IProfileRegistry; -import org.eclipse.equinox.security.storage.EncodingUtils; import org.osgi.framework.*; import org.osgi.service.prefs.BackingStoreException; @@ -144,7 +143,7 @@ public class ProfilePreferences extends EclipsePreferences { * agent location. Never returns null; throws an exception if the agent could not be found. */ protected IProvisioningAgent getAgent(String segment) throws BackingStoreException { - String locationString = EncodingUtils.decodeSlashes(segment); + String locationString = SlashEncode.decode(segment); Exception failure = null; IProvisioningAgent result = null; try { diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/SlashEncode.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/SlashEncode.java new file mode 100644 index 000000000..9c1a1854a --- /dev/null +++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/SlashEncode.java @@ -0,0 +1,89 @@ +package org.eclipse.equinox.internal.p2.engine; + +/** + * Utility class to encode forward slash characters so that strings containing + * forward slashes can be used as node names with secure preferences. It is + * the responsibility of the consumer to manually encode such strings before + * attempting to obtain corresponding nodes from secure preferences. + * <p> + * Internally, the class uses a subset of JIT encoding. The forward slashes + * and backward slashes are encoded. + * </p><p> + * This class is not intended to be instantiated or subclassed by users. + * </p> + */ +final public class SlashEncode { + + final private static char SLASH = '/'; + final private static char BACK_SLASH = '\\'; + + final private static String ENCODED_SLASH = "\\2f"; //$NON-NLS-1$ + final private static String ENCODED_BACK_SLASH = "\\5c"; //$NON-NLS-1$ + + static public String decode(String str) { + if (str == null) + return null; + int size = str.length(); + if (size == 0) + return str; + + StringBuffer processed = new StringBuffer(size); + int processedPos = 0; + + for (int i = 0; i < size; i++) { + char c = str.charAt(i); + if (c == BACK_SLASH) { + if (i + 2 >= size) + continue; + String encoded = str.substring(i, i + 3); + char decoded = 0; + if (ENCODED_SLASH.equals(encoded)) + decoded = SLASH; + else if (ENCODED_BACK_SLASH.equals(encoded)) + decoded = BACK_SLASH; + if (decoded == 0) + continue; + if (i > processedPos) + processed.append(str.substring(processedPos, i)); + processed.append(decoded); + processedPos = i + 3; + i += 2; // skip over remaining encoded portion + } + } + if (processedPos == 0) + return str; + if (processedPos < size) + processed.append(str.substring(processedPos)); + return new String(processed); + } + + static public String encode(String str) { + if (str == null) + return null; + int size = str.length(); + if (size == 0) + return str; + + StringBuffer processed = new StringBuffer(size); + int processedPos = 0; + + for (int i = 0; i < size; i++) { + char c = str.charAt(i); + if (c == SLASH || c == BACK_SLASH) { + if (i > processedPos) + processed.append(str.substring(processedPos, i)); + if (c == SLASH) + processed.append(ENCODED_SLASH); + else if (c == BACK_SLASH) + processed.append(ENCODED_BACK_SLASH); + processedPos = i + 1; + } + } + if (processedPos == 0) + return str; + if (processedPos < size) + processed.append(str.substring(processedPos)); + return new String(processed); + } + +} diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/phases/Collect.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/phases/Collect.java index 640bf0807..e53c94754 100644 --- a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/phases/Collect.java +++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/internal/p2/engine/phases/Collect.java @@ -67,6 +67,9 @@ public class Collect extends InstallableUnitPhase { } protected IStatus completePhase(IProgressMonitor monitor, IProfile profile, Map<String, Object> parameters) { + // do nothing for rollback if the provisioning has been cancelled + if (monitor.isCanceled()) + return Status.OK_STATUS; @SuppressWarnings("unchecked") List<IArtifactRequest[]> artifactRequests = (List<IArtifactRequest[]>) parameters.get(PARM_ARTIFACT_REQUESTS); // it happens when rollbacking diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/ProfileScope.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/ProfileScope.java index 2a4c26554..bbb297945 100644 --- a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/ProfileScope.java +++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/ProfileScope.java @@ -15,8 +15,8 @@ import org.eclipse.core.runtime.Assert; import org.eclipse.core.runtime.IPath; import org.eclipse.core.runtime.preferences.IEclipsePreferences; import org.eclipse.core.runtime.preferences.IScopeContext; +import org.eclipse.equinox.internal.p2.engine.SlashEncode; import org.eclipse.equinox.p2.core.IAgentLocation; -import org.eclipse.equinox.security.storage.EncodingUtils; /** * A profile scope contains the preferences associated with a particular profile @@ -72,7 +72,7 @@ public final class ProfileScope implements IScopeContext { public IEclipsePreferences getNode(String qualifier) { if (qualifier == null) throw new IllegalArgumentException(); - String locationString = EncodingUtils.encodeSlashes(location.getRootLocation().toString()); + String locationString = SlashEncode.encode(location.getRootLocation().toString()); //format is /profile/{agentLocationURI}/{profileId}/qualifier return (IEclipsePreferences) PreferencesService.getDefault().getRootNode().node(getName()).node(locationString).node(profileId).node(qualifier); } diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/spi/ProvisioningAction.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/spi/ProvisioningAction.java index ef88e2ae8..fb80a02e1 100644 --- a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/spi/ProvisioningAction.java +++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/spi/ProvisioningAction.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2007, 2010 IBM Corporation and others. + * Copyright (c) 2007, 2012 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -7,6 +7,7 @@ * * Contributors: * IBM Corporation - initial API and implementation + * Landmark Graphics Corporation - bug 397183 *******************************************************************************/ package org.eclipse.equinox.p2.engine.spi; @@ -18,10 +19,12 @@ import org.eclipse.core.runtime.IStatus; */ public abstract class ProvisioningAction { - private Memento memento = new Memento(); + private Memento memento; private Touchpoint touchpoint; protected Memento getMemento() { + if (memento == null) + memento = new Memento(); return memento; } @@ -29,6 +32,16 @@ public abstract class ProvisioningAction { public abstract IStatus undo(Map<String, Object> parameters); + /** + * This method is meant for provisioning actions that need to communicate the result of their execution + * to subsequent actions. + * This method is only invoked by p2 once execute() has been executed. + * @return the result of the action execution. + */ + public Value<?> getResult() { + return Value.NO_VALUE; + } + // TODO: these probably should not be visible public void setTouchpoint(Touchpoint touchpoint) { this.touchpoint = touchpoint; diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/spi/Touchpoint.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/spi/Touchpoint.java index 47da6df89..4142d8687 100644 --- a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/spi/Touchpoint.java +++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/spi/Touchpoint.java @@ -28,6 +28,7 @@ public abstract class Touchpoint { * @param actionId the unqualified action id * @return the qualified action id * @noreference This method is not intended to be referenced by clients. + * @since 2.0 */ public String qualifyAction(String actionId) { return actionId; diff --git a/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/spi/Value.java b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/spi/Value.java new file mode 100644 index 000000000..15ecf1599 --- /dev/null +++ b/bundles/org.eclipse.equinox.p2.engine/src/org/eclipse/equinox/p2/engine/spi/Value.java @@ -0,0 +1,30 @@ +/******************************************************************************* + * Copyright (c) 2012 Landmark Graphics Corporation + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Landmark Graphics Corporation - initial API and implementation + *******************************************************************************/ +package org.eclipse.equinox.p2.engine.spi; + +public class Value<T> { + public static final Value<Object> NO_VALUE = new Value<Object>(null); + private T value; + private Class<T> clazz; + + public Value(T val) { + value = val; + } + + public T getValue() { + return value; + } + + public Class<T> getClazz() { + return clazz; + } + +} diff --git a/bundles/org.eclipse.equinox.p2.installer/.settings/org.eclipse.pde.api.tools.prefs b/bundles/org.eclipse.equinox.p2.installer/.settings/org.eclipse.pde.api.tools.prefs deleted file mode 100644 index 7f465d533..000000000 --- a/bundles/org.eclipse.equinox.p2.installer/.settings/org.eclipse.pde.api.tools.prefs +++ /dev/null @@ -1,94 +0,0 @@ -#Wed Feb 17 13:55:35 EST 2010 -ANNOTATION_ELEMENT_TYPE_ADDED_METHOD_WITHOUT_DEFAULT_VALUE=Error -ANNOTATION_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error -ANNOTATION_ELEMENT_TYPE_REMOVED_FIELD=Error -ANNOTATION_ELEMENT_TYPE_REMOVED_METHOD=Error -ANNOTATION_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error -API_COMPONENT_ELEMENT_TYPE_REMOVED_API_TYPE=Error -API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_API_TYPE=Error -API_COMPONENT_ELEMENT_TYPE_REMOVED_REEXPORTED_TYPE=Error -API_COMPONENT_ELEMENT_TYPE_REMOVED_TYPE=Error -CLASS_ELEMENT_TYPE_ADDED_METHOD=Error -CLASS_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error -CLASS_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error -CLASS_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error -CLASS_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error -CLASS_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error -CLASS_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error -CLASS_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error -CLASS_ELEMENT_TYPE_REMOVED_CONSTRUCTOR=Error -CLASS_ELEMENT_TYPE_REMOVED_FIELD=Error -CLASS_ELEMENT_TYPE_REMOVED_METHOD=Error -CLASS_ELEMENT_TYPE_REMOVED_SUPERCLASS=Error -CLASS_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error -CLASS_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error -CONSTRUCTOR_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error -CONSTRUCTOR_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error -CONSTRUCTOR_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error -CONSTRUCTOR_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error -ENUM_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error -ENUM_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error -ENUM_ELEMENT_TYPE_REMOVED_ENUM_CONSTANT=Error -ENUM_ELEMENT_TYPE_REMOVED_FIELD=Error -ENUM_ELEMENT_TYPE_REMOVED_METHOD=Error -ENUM_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error -FIELD_ELEMENT_TYPE_ADDED_VALUE=Error -FIELD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error -FIELD_ELEMENT_TYPE_CHANGED_FINAL_TO_NON_FINAL_STATIC_CONSTANT=Error -FIELD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error -FIELD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error -FIELD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error -FIELD_ELEMENT_TYPE_CHANGED_TYPE=Error -FIELD_ELEMENT_TYPE_CHANGED_VALUE=Error -FIELD_ELEMENT_TYPE_REMOVED_TYPE_ARGUMENT=Error -FIELD_ELEMENT_TYPE_REMOVED_VALUE=Error -ILLEGAL_EXTEND=Warning -ILLEGAL_IMPLEMENT=Warning -ILLEGAL_INSTANTIATE=Warning -ILLEGAL_OVERRIDE=Warning -ILLEGAL_REFERENCE=Warning -INTERFACE_ELEMENT_TYPE_ADDED_FIELD=Error -INTERFACE_ELEMENT_TYPE_ADDED_METHOD=Error -INTERFACE_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error -INTERFACE_ELEMENT_TYPE_ADDED_SUPER_INTERFACE_WITH_METHODS=Error -INTERFACE_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error -INTERFACE_ELEMENT_TYPE_CHANGED_CONTRACTED_SUPERINTERFACES_SET=Error -INTERFACE_ELEMENT_TYPE_CHANGED_TYPE_CONVERSION=Error -INTERFACE_ELEMENT_TYPE_REMOVED_FIELD=Error -INTERFACE_ELEMENT_TYPE_REMOVED_METHOD=Error -INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_MEMBER=Error -INTERFACE_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error -INVALID_JAVADOC_TAG=Ignore -INVALID_REFERENCE_IN_SYSTEM_LIBRARIES=Error -LEAK_EXTEND=Warning -LEAK_FIELD_DECL=Warning -LEAK_IMPLEMENT=Warning -LEAK_METHOD_PARAM=Warning -LEAK_METHOD_RETURN_TYPE=Warning -METHOD_ELEMENT_TYPE_ADDED_RESTRICTIONS=Error -METHOD_ELEMENT_TYPE_ADDED_TYPE_PARAMETER=Error -METHOD_ELEMENT_TYPE_CHANGED_DECREASE_ACCESS=Error -METHOD_ELEMENT_TYPE_CHANGED_NON_ABSTRACT_TO_ABSTRACT=Error -METHOD_ELEMENT_TYPE_CHANGED_NON_FINAL_TO_FINAL=Error -METHOD_ELEMENT_TYPE_CHANGED_NON_STATIC_TO_STATIC=Error -METHOD_ELEMENT_TYPE_CHANGED_STATIC_TO_NON_STATIC=Error -METHOD_ELEMENT_TYPE_CHANGED_VARARGS_TO_ARRAY=Error -METHOD_ELEMENT_TYPE_REMOVED_ANNOTATION_DEFAULT_VALUE=Error -METHOD_ELEMENT_TYPE_REMOVED_TYPE_PARAMETER=Error -TYPE_PARAMETER_ELEMENT_TYPE_ADDED_CLASS_BOUND=Error -TYPE_PARAMETER_ELEMENT_TYPE_ADDED_INTERFACE_BOUND=Error -TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_CLASS_BOUND=Error -TYPE_PARAMETER_ELEMENT_TYPE_CHANGED_INTERFACE_BOUND=Error -TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_CLASS_BOUND=Error -TYPE_PARAMETER_ELEMENT_TYPE_REMOVED_INTERFACE_BOUND=Error -UNUSED_PROBLEM_FILTERS=Warning -automatically_removed_unused_problem_filters=false -eclipse.preferences.version=1 -incompatible_api_component_version=Error -incompatible_api_component_version_include_major_without_breaking_change=Disabled -incompatible_api_component_version_include_minor_without_api_change=Disabled -invalid_since_tag_version=Error -malformed_since_tag=Error -missing_since_tag=Error -report_api_breakage_when_major_version_incremented=Disabled -report_resolution_errors_api_component=Warning diff --git a/bundles/org.eclipse.equinox.p2.installer/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.p2.installer/META-INF/MANIFEST.MF index c83f1ca16..63531f794 100644 --- a/bundles/org.eclipse.equinox.p2.installer/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.equinox.p2.installer/META-INF/MANIFEST.MF @@ -21,7 +21,6 @@ Require-Bundle: org.eclipse.osgi;bundle-version="[3.7.0,4.0.0)", org.eclipse.equinox.p2.repository;bundle-version="2.1.0", org.eclipse.equinox.p2.transport.ecf;bundle-version="1.0.0" Bundle-RequiredExecutionEnvironment: J2SE-1.5, - J2SE-1.4, CDC-1.1/Foundation-1.1 Export-Package: org.eclipse.equinox.internal.p2.installer;x-internal:=true, org.eclipse.equinox.internal.p2.installer.ui;x-internal:=true, diff --git a/bundles/org.eclipse.equinox.p2.jarprocessor/.classpath b/bundles/org.eclipse.equinox.p2.jarprocessor/.classpath index 0179ed600..a6d1c717d 100644 --- a/bundles/org.eclipse.equinox.p2.jarprocessor/.classpath +++ b/bundles/org.eclipse.equinox.p2.jarprocessor/.classpath @@ -1,8 +1,8 @@ -<?xml version="1.0" encoding="UTF-8"?> -<classpath> - <classpathentry kind="src" path="src"/> - <classpathentry kind="src" output="bin_ant" path="src_ant"/> - <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/CDC-1.1%Foundation-1.1"/> - <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/> - <classpathentry kind="output" path="bin"/> -</classpath> +<?xml version="1.0" encoding="UTF-8"?>
+<classpath>
+ <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/J2SE-1.5"/>
+ <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
+ <classpathentry kind="src" path="src"/>
+ <classpathentry kind="src" output="bin_ant" path="src_ant"/>
+ <classpathentry kind="output" path="bin"/>
+</classpath>
diff --git a/bundles/org.eclipse.equinox.p2.jarprocessor/.settings/org.eclipse.jdt.core.prefs b/bundles/org.eclipse.equinox.p2.jarprocessor/.settings/org.eclipse.jdt.core.prefs index a46514810..c527e2e02 100644 --- a/bundles/org.eclipse.equinox.p2.jarprocessor/.settings/org.eclipse.jdt.core.prefs +++ b/bundles/org.eclipse.equinox.p2.jarprocessor/.settings/org.eclipse.jdt.core.prefs @@ -1,345 +1,346 @@ -#Thu Sep 24 13:53:16 EDT 2009 -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert -org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line -org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert -org.eclipse.jdt.core.compiler.problem.unsafeTypeOperation=warning -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert -org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line -org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert -org.eclipse.jdt.core.compiler.problem.localVariableHiding=warning -org.eclipse.jdt.core.formatter.alignment_for_assignment=0 -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert -org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert -org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.2 -org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert -org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error -org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false -org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false -org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert -org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert +eclipse.preferences.version=1 +org.eclipse.jdt.core.builder.cleanOutputFolder=clean +org.eclipse.jdt.core.builder.duplicateResourceTask=warning +org.eclipse.jdt.core.builder.invalidClasspath=abort +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter=*.launch +org.eclipse.jdt.core.circularClasspath=error +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.5 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate +org.eclipse.jdt.core.compiler.doc.comment.support=enabled +org.eclipse.jdt.core.compiler.maxProblemPerUnit=1000 +org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.autoboxing=ignore +org.eclipse.jdt.core.compiler.problem.deprecation=warning +org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled +org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled +org.eclipse.jdt.core.compiler.problem.discouragedReference=error org.eclipse.jdt.core.compiler.problem.emptyStatement=warning -org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=public -org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert -org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=warning -org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert -org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert -org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore +org.eclipse.jdt.core.compiler.problem.fatalOptionalError=enabled org.eclipse.jdt.core.compiler.problem.fieldHiding=warning -org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert -org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning -org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert -org.eclipse.jdt.core.formatter.blank_lines_after_imports=1 -org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public -org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.compiler.problem.finalParameterBound=ignore org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning +org.eclipse.jdt.core.compiler.problem.forbiddenReference=error +org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning +org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning +org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=ignore +org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=warning +org.eclipse.jdt.core.compiler.problem.invalidJavadoc=error +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=private +org.eclipse.jdt.core.compiler.problem.localVariableHiding=warning +org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning +org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=enabled +org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public +org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=enabled +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=public +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=ignore +org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning +org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning +org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=warning +org.eclipse.jdt.core.compiler.problem.nullReference=ignore +org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore -org.eclipse.jdt.core.formatter.comment.format_source_code=true -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert -org.eclipse.jdt.core.compiler.debug.localVariable=generate -org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true -org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert -org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1 -org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert -org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=warning -org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert -org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false +org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning +org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore +org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning +org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore +org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled +org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning +org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=warning -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert -org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1 -org.eclipse.jdt.core.classpath.exclusionPatterns=enabled -org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16 -org.eclipse.jdt.core.formatter.insert_new_line_after_annotation=insert -org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1 -org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert -org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line -org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve -org.eclipse.jdt.core.formatter.comment.format_header=false -org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert -org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert -org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16 -org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert -org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16 -org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert -org.eclipse.jdt.core.formatter.comment.line_length=80 -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert -org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert +org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning +org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning +org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=warning +org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning +org.eclipse.jdt.core.compiler.problem.unnecessaryElse=warning +org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning +org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore +org.eclipse.jdt.core.compiler.problem.unsafeTypeOperation=warning +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=enabled +org.eclipse.jdt.core.compiler.problem.unusedImport=error +org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLocal=warning +org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled -org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert -org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert -org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert -org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert -org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning -org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert -org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert -org.eclipse.jdt.core.builder.cleanOutputFolder=clean org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=enabled -org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=do not insert -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert -org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning -org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert -org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=false -org.eclipse.jdt.core.formatter.continuation_indentation=2 -org.eclipse.jdt.core.compiler.problem.invalidJavadoc=error -org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=enabled +org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=error +org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning +org.eclipse.jdt.core.compiler.source=1.5 +org.eclipse.jdt.core.formatter.align_type_members_on_columns=false +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_assignment=0 +org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_compact_if=16 +org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80 +org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0 +org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16 +org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16 +org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16 -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert -org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled -org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert +org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16 +org.eclipse.jdt.core.formatter.blank_lines_after_imports=1 +org.eclipse.jdt.core.formatter.blank_lines_after_package=1 +org.eclipse.jdt.core.formatter.blank_lines_before_field=0 +org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0 +org.eclipse.jdt.core.formatter.blank_lines_before_imports=1 +org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1 org.eclipse.jdt.core.formatter.blank_lines_before_method=1 -org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=enabled -org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=false -org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1 +org.eclipse.jdt.core.formatter.blank_lines_before_package=0 +org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1 org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1 -org.eclipse.jdt.core.builder.resourceCopyExclusionFilter=*.launch -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert -org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert +org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line -org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert -org.eclipse.jdt.core.incompleteClasspath=error -org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert -org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16 -org.eclipse.jdt.core.formatter.join_lines_in_comments=true -org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true -org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=enabled -org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert -org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0 +org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line +org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false +org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false org.eclipse.jdt.core.formatter.comment.format_block_comments=false -org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert -org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16 -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=insert +org.eclipse.jdt.core.formatter.comment.format_header=false org.eclipse.jdt.core.formatter.comment.format_html=true -org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert -org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert -org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16 -org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert -org.eclipse.jdt.core.compiler.problem.autoboxing=ignore -org.eclipse.jdt.core.compiler.problem.enumIdentifier=warning -org.eclipse.jdt.core.compiler.problem.fallthroughCase=ignore -org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=do not insert -org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled -org.eclipse.jdt.core.compiler.problem.fatalOptionalError=enabled -org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert -org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert -org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning -org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert -org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line -org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning -org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert -org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16 -org.eclipse.jdt.core.compiler.problem.unnecessaryElse=warning -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert -org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore -org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning -org.eclipse.jdt.core.compiler.problem.forbiddenReference=error -org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert -org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert -org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_member=insert -org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert -org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert -org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert -org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true +org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=false +org.eclipse.jdt.core.formatter.comment.format_line_comments=false +org.eclipse.jdt.core.formatter.comment.format_source_code=true +org.eclipse.jdt.core.formatter.comment.indent_parameter_description=false +org.eclipse.jdt.core.formatter.comment.indent_root_tags=false +org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert -org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16 -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert -org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert -org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.comment.line_length=80 +org.eclipse.jdt.core.formatter.compact_else_if=true +org.eclipse.jdt.core.formatter.continuation_indentation=2 +org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2 +org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true +org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true +org.eclipse.jdt.core.formatter.indent_empty_lines=false +org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true +org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true +org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true +org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=true +org.eclipse.jdt.core.formatter.indentation.size=4 +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert -org.eclipse.jdt.core.circularClasspath=error -org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert +org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert -org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16 -org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert -org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert -org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line +org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert -org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=ignore -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert -org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert -org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert -org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0 -org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning -org.eclipse.jdt.core.formatter.tabulation.char=tab org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert -org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert -org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false -org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false -org.eclipse.jdt.core.formatter.compact_else_if=true -org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert -org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert -org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line -org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false -org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning -org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning -org.eclipse.jdt.core.formatter.align_type_members_on_columns=false -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert -org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert +org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert -org.eclipse.jdt.core.compiler.problem.finalParameterBound=ignore -org.eclipse.jdt.core.formatter.join_wrapped_lines=true -org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=insert org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert -org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert -org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true -org.eclipse.jdt.core.compiler.problem.discouragedReference=error -org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16 -org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false -org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert -org.eclipse.jdt.core.formatter.comment.format_line_comments=false -org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert -org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert -org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert -org.eclipse.jdt.core.formatter.comment.indent_parameter_description=false -org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert -org.eclipse.jdt.core.formatter.indentation.size=4 -org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=enabled -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=insert org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert -org.eclipse.jdt.core.compiler.debug.sourceFile=generate -org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert -org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16 -org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert -org.eclipse.jdt.core.formatter.comment.indent_root_tags=false -org.eclipse.jdt.core.compiler.problem.deprecation=warning -org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert -org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=private -org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore -org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16 -org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert -org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert -org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=enabled -org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert -org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false -org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true -org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert -org.eclipse.jdt.core.formatter.blank_lines_before_package=0 org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert -org.eclipse.jdt.core.formatter.indent_empty_lines=false -org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert -org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16 +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert -org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert -org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert -org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=ignore -org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line -org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0 -org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80 -org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert -org.eclipse.jdt.core.compiler.problem.unusedImport=error -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert -org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert -org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=true -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert -org.eclipse.jdt.core.compiler.problem.unusedLabel=warning -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert -org.eclipse.jdt.core.builder.invalidClasspath=abort -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert -org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert -org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore -org.eclipse.jdt.core.incompatibleJDKLevel=ignore -org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert -org.eclipse.jdt.core.compiler.problem.nullReference=ignore -org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert -org.eclipse.jdt.core.compiler.debug.lineNumber=generate -org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore -org.eclipse.jdt.core.formatter.blank_lines_before_imports=1 -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert -org.eclipse.jdt.core.formatter.alignment_for_compact_if=16 -org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning -org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=disabled -org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning -org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert -org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert +org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert +org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert +org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert -org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert -org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert -org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2 +org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.join_lines_in_comments=true +org.eclipse.jdt.core.formatter.join_wrapped_lines=true +org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false +org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false +org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false +org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false org.eclipse.jdt.core.formatter.lineSplit=800 -org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=enabled -org.eclipse.jdt.core.compiler.maxProblemPerUnit=1000 -org.eclipse.jdt.core.compiler.source=1.3 -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=do not insert -org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert +org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false +org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false +org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0 +org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1 +org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=false +org.eclipse.jdt.core.formatter.tabulation.char=tab org.eclipse.jdt.core.formatter.tabulation.size=4 -org.eclipse.jdt.core.compiler.problem.assertIdentifier=warning -org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line -org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert -org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1 -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert -org.eclipse.jdt.core.builder.duplicateResourceTask=warning -org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert -org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert -org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=insert -org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore -org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert -org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning -org.eclipse.jdt.core.compiler.problem.unusedLocal=warning -org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert -org.eclipse.jdt.core.compiler.doc.comment.support=enabled -org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert -org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert -org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert -org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning -eclipse.preferences.version=1 -org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore -org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert -org.eclipse.jdt.core.compiler.compliance=1.4 -org.eclipse.jdt.core.formatter.blank_lines_after_package=1 -org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16 -org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert -org.eclipse.jdt.core.formatter.blank_lines_before_field=0 +org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false +org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true +org.eclipse.jdt.core.incompatibleJDKLevel=ignore +org.eclipse.jdt.core.incompleteClasspath=error diff --git a/bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/p2/query/MatchQuery.java b/bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/p2/query/MatchQuery.java index f320f7e18..52aaa8909 100644 --- a/bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/p2/query/MatchQuery.java +++ b/bundles/org.eclipse.equinox.p2.metadata/src/org/eclipse/equinox/p2/query/MatchQuery.java @@ -46,6 +46,7 @@ public abstract class MatchQuery<T> implements IMatchQuery<T> { * * @noreference This method is not intended to be referenced by clients. * Clients should call {@link #perform(Iterator)} + * @since 2.0 */ public abstract boolean isMatch(T candidate); diff --git a/bundles/org.eclipse.equinox.p2.operations/pom.xml b/bundles/org.eclipse.equinox.p2.operations/pom.xml index b73f6d948..992cbe784 100644 --- a/bundles/org.eclipse.equinox.p2.operations/pom.xml +++ b/bundles/org.eclipse.equinox.p2.operations/pom.xml @@ -21,6 +21,6 @@ </parent> <groupId>org.eclipse</groupId> <artifactId>org.eclipse.equinox.p2.operations</artifactId> - <version>2.2.0-SNAPSHOT</version> + <version>2.2.100-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> </project> diff --git a/bundles/org.eclipse.equinox.p2.publisher.eclipse/pom.xml b/bundles/org.eclipse.equinox.p2.publisher.eclipse/pom.xml index 30ad6cb30..95497f149 100644 --- a/bundles/org.eclipse.equinox.p2.publisher.eclipse/pom.xml +++ b/bundles/org.eclipse.equinox.p2.publisher.eclipse/pom.xml @@ -13,4 +13,17 @@ <artifactId>org.eclipse.equinox.p2.publisher.eclipse</artifactId> <version>1.1.100-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> + + <build> + <plugins> + <plugin> + <groupId>org.eclipse.tycho</groupId> + <artifactId>target-platform-configuration</artifactId> + <configuration> + <executionEnvironment>J2SE-1.5</executionEnvironment> + </configuration> + </plugin> + </plugins> + </build> + </project> diff --git a/bundles/org.eclipse.equinox.p2.publisher/build.properties b/bundles/org.eclipse.equinox.p2.publisher/build.properties index e4ae6a518..320f62786 100644 --- a/bundles/org.eclipse.equinox.p2.publisher/build.properties +++ b/bundles/org.eclipse.equinox.p2.publisher/build.properties @@ -18,3 +18,6 @@ bin.includes = META-INF/,\ profiles/,\ plugin.properties javacWarnings..=+unusedThrown +src.includes = about.html,\ + src/,\ + META-INF/ diff --git a/bundles/org.eclipse.equinox.p2.repository.tools/.settings/org.eclipse.jdt.core.prefs b/bundles/org.eclipse.equinox.p2.repository.tools/.settings/org.eclipse.jdt.core.prefs index b07f19588..06d68bd41 100644 --- a/bundles/org.eclipse.equinox.p2.repository.tools/.settings/org.eclipse.jdt.core.prefs +++ b/bundles/org.eclipse.equinox.p2.repository.tools/.settings/org.eclipse.jdt.core.prefs @@ -1,4 +1,3 @@ -#Mon Dec 28 06:58:36 CET 2009 eclipse.preferences.version=1 org.eclipse.jdt.core.builder.cleanOutputFolder=clean org.eclipse.jdt.core.builder.duplicateResourceTask=warning @@ -8,7 +7,7 @@ org.eclipse.jdt.core.circularClasspath=error org.eclipse.jdt.core.classpath.exclusionPatterns=enabled org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled -org.eclipse.jdt.core.compiler.codegen.targetPlatform=jsr14 +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.5 org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve org.eclipse.jdt.core.compiler.compliance=1.5 org.eclipse.jdt.core.compiler.debug.lineNumber=generate diff --git a/bundles/org.eclipse.equinox.p2.repository.tools/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.p2.repository.tools/META-INF/MANIFEST.MF index be6574d47..41f4121ba 100644 --- a/bundles/org.eclipse.equinox.p2.repository.tools/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.equinox.p2.repository.tools/META-INF/MANIFEST.MF @@ -13,9 +13,7 @@ Export-Package: org.eclipse.equinox.p2.internal.repository.comparator;x-internal org.eclipse.equinox.p2.repository.tools.analyzer;version="2.0.0", org.eclipse.equinox.p2.repository.tools.comparator;version="2.0.0" Require-Bundle: org.eclipse.equinox.common;bundle-version="3.3.0", org.eclipse.equinox.registry -Bundle-RequiredExecutionEnvironment: J2SE-1.5, - J2SE-1.4, - CDC-1.1/Foundation-1.1 +Bundle-RequiredExecutionEnvironment: J2SE-1.5 Bundle-ActivationPolicy: lazy Import-Package: org.eclipse.equinox.app;version="1.0.0", org.eclipse.equinox.internal.p2.artifact.repository, diff --git a/bundles/org.eclipse.equinox.p2.tests.discovery/pom.xml b/bundles/org.eclipse.equinox.p2.tests.discovery/pom.xml index 91b7edf43..ba3c838d5 100644 --- a/bundles/org.eclipse.equinox.p2.tests.discovery/pom.xml +++ b/bundles/org.eclipse.equinox.p2.tests.discovery/pom.xml @@ -12,4 +12,15 @@ <artifactId>org.eclipse.equinox.p2.tests.discovery</artifactId> <version>1.0.0-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> + <build> + <plugins> + <plugin> + <groupId>org.eclipse.tycho</groupId> + <artifactId>target-platform-configuration</artifactId> + <configuration> + <executionEnvironment>J2SE-1.5</executionEnvironment> + </configuration> + </plugin> + </plugins> + </build> </project> diff --git a/bundles/org.eclipse.equinox.p2.tests.ui/pom.xml b/bundles/org.eclipse.equinox.p2.tests.ui/pom.xml index 435d5f1b3..d6ad2033e 100644 --- a/bundles/org.eclipse.equinox.p2.tests.ui/pom.xml +++ b/bundles/org.eclipse.equinox.p2.tests.ui/pom.xml @@ -29,6 +29,13 @@ <build> <plugins> + <plugin> + <groupId>org.eclipse.tycho</groupId> + <artifactId>target-platform-configuration</artifactId> + <configuration> + <executionEnvironment>J2SE-1.5</executionEnvironment> + </configuration> + </plugin> <plugin> <groupId>org.eclipse.tycho</groupId> <artifactId>tycho-surefire-plugin</artifactId> diff --git a/bundles/org.eclipse.equinox.p2.tests.verifier/pom.xml b/bundles/org.eclipse.equinox.p2.tests.verifier/pom.xml index bcafe57d8..c43be8844 100644 --- a/bundles/org.eclipse.equinox.p2.tests.verifier/pom.xml +++ b/bundles/org.eclipse.equinox.p2.tests.verifier/pom.xml @@ -12,4 +12,15 @@ <artifactId>org.eclipse.equinox.p2.tests.verifier</artifactId> <version>1.0.100-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> + <build> + <plugins> + <plugin> + <groupId>org.eclipse.tycho</groupId> + <artifactId>target-platform-configuration</artifactId> + <configuration> + <executionEnvironment>J2SE-1.5</executionEnvironment> + </configuration> + </plugin> + </plugins> + </build> </project> diff --git a/bundles/org.eclipse.equinox.p2.tests/download.eclipse.platform.for.p2.migration.tests.xml b/bundles/org.eclipse.equinox.p2.tests/download.eclipse.platform.for.p2.migration.tests.xml index 99dbc4954..18c28e5a6 100644 --- a/bundles/org.eclipse.equinox.p2.tests/download.eclipse.platform.for.p2.migration.tests.xml +++ b/bundles/org.eclipse.equinox.p2.tests/download.eclipse.platform.for.p2.migration.tests.xml @@ -35,9 +35,9 @@ </target> <target name="download.for.unix" unless="isWindows"> - <get src="http://mirror.csclub.uwaterloo.ca/eclipse/eclipse/downloads/drops/R-3.7.1-201109091335/eclipse-platform-3.7.1-linux-gtk.tar.gz" dest="eclipse-indigo-platform.tar.gz" /> + <get src="http://eclipse.org/downloads/download.php?file=/eclipse/downloads/drops/R-3.7.2-201202080800/eclipse-platform-3.7.2-linux-gtk.tar.gz&r=1" dest="eclipse-indigo-platform.tar.gz" /> </target> <target name="download.for.windows" if="isWindows"> - <get src="http://mirror.csclub.uwaterloo.ca/eclipse/eclipse/downloads/drops/R-3.7.1-201109091335/eclipse-platform-3.7.1-win32.zip" dest="eclipse-indigo-platform.zip" /> + <get src="http://eclipse.org/downloads/download.php?file=/eclipse/downloads/drops/R-3.7.2-201202080800/eclipse-platform-3.7.2-win32.zip&r=1" dest="eclipse-indigo-platform.zip" /> </target> </project> diff --git a/bundles/org.eclipse.equinox.p2.tests/plugin.xml b/bundles/org.eclipse.equinox.p2.tests/plugin.xml index 021e9cae4..70f56fb29 100644 --- a/bundles/org.eclipse.equinox.p2.tests/plugin.xml +++ b/bundles/org.eclipse.equinox.p2.tests/plugin.xml @@ -45,6 +45,30 @@ version="1.0.0"> </action> </extension> + <extension + point="org.eclipse.equinox.p2.engine.actions"> + <action + class="org.eclipse.equinox.p2.tests.engine.VariableTest$Action" + name="test.actionForVariableTesting" + version="1.0.0"> + </action> + </extension> + <extension + point="org.eclipse.equinox.p2.engine.actions"> + <action + class="org.eclipse.equinox.p2.tests.engine.VariableTest2$Action" + name="test.actionForVariableTesting2" + version="1.0.0"> + </action> + </extension> + <extension + point="org.eclipse.equinox.p2.engine.actions"> + <action + class="org.eclipse.equinox.p2.tests.engine.VariableTest3$Action" + name="test.actionForVariableTesting3" + version="1.0.0"> + </action> + </extension> <extension point="org.eclipse.equinox.p2.engine.actions"> <action diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/processing/ProcessingStepHandlerTest.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/processing/ProcessingStepHandlerTest.java index 4812afd09..b7d7aa35b 100644 --- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/processing/ProcessingStepHandlerTest.java +++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/artifact/repository/processing/ProcessingStepHandlerTest.java @@ -136,8 +136,8 @@ public class ProcessingStepHandlerTest extends AbstractProvisioningTest { assertTrue("Step is not ready.", status.isOK()); InputStream inputStream = TestActivator.getContext().getBundle().getEntry("testData/jarprocessor.jar.pack.gz").openStream(); FileUtils.copyStream(inputStream, true, testStream, true); - //the value 34759 obtained by manually unpacking the test artifact using unpack200.exe from sun 7u2 JRE - assertEquals(34759, result.size()); + //the value 35062 obtained by manually unpacking the test artifact using unpack200.exe from sun 7u9 JRE + assertEquals(35062, result.size()); } public void testCreateByteShifterPS() { diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/engine/AllTests.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/engine/AllTests.java index 69100ff0b..1248def6c 100644 --- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/engine/AllTests.java +++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/engine/AllTests.java @@ -37,6 +37,9 @@ public class AllTests extends TestCase { suite.addTestSuite(TouchpointManagerTest.class); suite.addTestSuite(TouchpointTest.class); suite.addTestSuite(ProvisioningEventTest.class); + suite.addTestSuite(VariableTest.class); + suite.addTestSuite(VariableTest2.class); + suite.addTestSuite(VariableTest3.class); return suite; } diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/engine/PhaseTest.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/engine/PhaseTest.java index 9b20dc28d..0ccdbe100 100644 --- a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/engine/PhaseTest.java +++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/engine/PhaseTest.java @@ -15,9 +15,15 @@ import java.io.IOException; import java.util.*; import org.eclipse.core.runtime.*; import org.eclipse.equinox.internal.p2.engine.*; +import org.eclipse.equinox.internal.p2.engine.phases.Collect; +import org.eclipse.equinox.internal.provisional.p2.core.eventbus.ProvisioningListener; import org.eclipse.equinox.p2.engine.*; import org.eclipse.equinox.p2.engine.spi.ProvisioningAction; import org.eclipse.equinox.p2.metadata.*; +import org.eclipse.equinox.p2.query.QueryUtil; +import org.eclipse.equinox.p2.repository.artifact.IArtifactRepositoryManager; +import org.eclipse.equinox.p2.repository.metadata.IMetadataRepository; +import org.eclipse.equinox.p2.repository.metadata.IMetadataRepositoryManager; import org.eclipse.equinox.p2.tests.AbstractProvisioningTest; /** @@ -303,4 +309,67 @@ public class PhaseTest extends AbstractProvisioningTest { assertEquals(TestAction.class, ((ParameterizedProvisioningAction) actionsList2.get(0)).getAction().getClass()); } + public void testCancelHappenBeforeCompleteCollectPhase() { + final String testDataLocation = "testData/mirror/mirrorSourceRepo3"; + Set<IInstallableUnit> ius = null; + try { + IArtifactRepositoryManager mgr = getArtifactRepositoryManager(); + mgr.loadRepository((getTestData("test artifact repo", testDataLocation).toURI()), null); + IMetadataRepositoryManager metaManager = getMetadataRepositoryManager(); + IMetadataRepository metaRepo = metaManager.loadRepository((getTestData("test metadata repo", testDataLocation).toURI()), null); + ius = metaRepo.query(QueryUtil.ALL_UNITS, null).toUnmodifiableSet(); + } catch (Exception e) { + fail("1.0", e); + } + class MyCollect extends Collect { + boolean isCancelled = false; + int progress = 0; + final static int THREHOLD = 2; + + public MyCollect(int weight) { + super(weight); + } + + @Override + protected List<ProvisioningAction> getActions(InstallableUnitOperand operand) { + List<ProvisioningAction> actions = super.getActions(operand); + if (actions != null) + progress++; + if (progress > THREHOLD) + isCancelled = true; + return actions; + } + } + final MyCollect collect = new MyCollect(100); + PhaseSet phaseSet = new TestPhaseSet(new Phase[] {collect}); + IProfile profile = createProfile("PhaseTest"); + IProvisioningPlan plan = engine.createPlan(profile, null); + for (IInstallableUnit iu : ius) + plan.addInstallableUnit(iu); + class TestListener implements ProvisioningListener { + boolean collectEvent = false; + + public void notify(EventObject o) { + if (o instanceof CollectEvent) + collectEvent = true; + } + + } + TestListener listener = new TestListener(); + getEventBus().addListener(listener); + try { + IStatus status = engine.perform(plan, phaseSet, new NullProgressMonitor() { + @Override + public boolean isCanceled() { + return collect.isCancelled; + } + }); + if (!status.matches(IStatus.CANCEL)) { + fail(status.toString()); + } + assertFalse("Collect actually happened!", listener.collectEvent); + } finally { + getEventBus().removeListener(listener); + } + } } diff --git a/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/engine/VariableTest.java b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/engine/VariableTest.java new file mode 100644 index 000000000..9df16a597 --- /dev/null +++ b/bundles/org.eclipse.equinox.p2.tests/src/org/eclipse/equinox/p2/tests/engine/VariableTest.java @@ -0,0 +1,115 @@ +/******************************************************************************* + * Copyright (c) 2012 Landmark Graphics Corporation + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * Landmark Graphics Corporation - initial API and implementation + *******************************************************************************/ +package org.eclipse.equinox.p2.tests.engine; + +import java.util.*; +import org.eclipse.core.runtime.*; +import org.eclipse.equinox.p2.engine.*; +import org.eclipse.equinox.p2.engine.spi.ProvisioningAction; +import org.eclipse.equinox.p2.engine.spi.Value; +import org.eclipse.equinox.p2.metadata.*; +import org.eclipse.equinox.p2.metadata.MetadataFactory.InstallableUnitDescription; +import org.eclipse.equinox.p2.tests.AbstractProvisioningTest; + +public class VariableTest extends AbstractProvisioningTest { + + private IInstallableUnit createIUWithVariable() { + InstallableUnitDescription description = new MetadataFactory.InstallableUnitDescription(); + description.setId("artifactWithZip"); + description.setVersion(Version.create("1.0.0")); + Map touchpointData = new HashMap(); + touchpointData.put("install", "test.actionForVariableTesting( arg1: expectedValue ); test.actionForVariableTesting ( arg1: ${lastResult} ); test.actionForVariableTesting ( arg1: ${lastResult} )"); + + description.addTouchpointData(MetadataFactory.createTouchpointData(touchpointData)); + + return MetadataFactory.createInstallableUnit(description); + } + + public void testVariable() { + Action.reinitForNextTest(); + Map properties = new HashMap(); + properties.put(IProfile.PROP_INSTALL_FOLDER, getTempFolder().getAbsolutePath()); + IProfile profile = createProfile("testVariable1", properties); + + Iterator ius = getInstallableUnits(profile); + assertFalse(ius.hasNext()); + + IProvisioningPlan plan = getEngine().createPlan(profile, null); + plan.addInstallableUnit(createIUWithVariable()); + IStatus result = getEngine().perform(plan, PhaseSetFactory.createPhaseSetIncluding(new String[] {PhaseSetFactory.PHASE_INSTALL}), new NullProgressMonitor()); + assertOK(result); + assertEquals("expectedValueaaa", Action.result); + } + + public void testUndo() { + Action.reinitForNextTest(); + Action.failMode = true; + Map properties = new HashMap(); + properties.put(IProfile.PROP_INSTALL_FOLDER, getTempFolder().getAbsolutePath()); + IProfile profile = createProfile("testVariable2", properties); + + Iterator ius = getInstallableUnits(profile); + assertFalse(ius.hasNext()); + + IProvisioningPlan plan = getEngine().createPlan(profile, null); + plan.addInstallableUnit(createIUWithVariable()); + IStatus result = getEngine().perform(plan, PhaseSetFactory.createPhaseSetIncluding(new String[] {PhaseSetFactory.PHASE_INSTALL}), new NullProgressMonitor()); + assertNotOK(result); + assertEquals(3, Action.inputValues.size()); + assertEquals(3, Action.undoValues.size()); + + //The undo values should be the same than the input values + assertEquals(Action.inputValues.get(0), Action.undoValues.get(2)); + assertEquals(Action.inputValues.get(1), Action.undoValues.get(1)); + assertEquals(Action.inputValues.get(2), Action.undoValues.get(0)); + } + + public static class Action extends ProvisioningAction { + public static String result; + public static boolean failMode; + private static int count = 0; + private static final int failAt = 3; + + public static ArrayList<String> inputValues = new ArrayList<String>(); + public static ArrayList<String> undoValues = new ArrayList<String>(); + + public static void reinitForNextTest() { + inputValues = new ArrayList<String>(); + undoValues = new ArrayList<String>(); + failMode = false; + count = 0; + } + + @Override + public IStatus execute(Map<String, Object> parameters) { + inputValues.add((String) parameters.get("arg1")); + System.out.println(this.hashCode()); + System.out.println((String) parameters.get("arg1")); + count++; + if (failMode && count == failAt) + throw new RuntimeException("GENERATED Exception"); + result = ((String) parameters.get("arg1")) + "a"; + + return Status.OK_STATUS; + } + + @Override + public IStatus undo(Map<String, Object> parameters) { + undoValues.add((String) parameters.get("arg1")); + System.out.println("undo arg --> " + (String) parameters.get("arg1")); + return Status.OK_STATUS; + } + + public Value<String> getResult() { + return new Value<String>(result); + } + } +} diff --git a/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/Messages.java b/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/Messages.java index 0d73c2a72..c8aade19e 100644 --- a/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/Messages.java +++ b/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/Messages.java @@ -47,6 +47,7 @@ public class Messages extends NLS { public static String download_cache_not_writeable; public static String unzipping; public static String param_not_set; + public static String chmod_param_cant_be_set_together; public static String copy_failed; public static String failed_backup_restore; public static String backup_file_failed; diff --git a/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/ActionConstants.java b/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/ActionConstants.java index daa448bd6..bb22ee514 100644 --- a/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/ActionConstants.java +++ b/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/ActionConstants.java @@ -33,4 +33,5 @@ public class ActionConstants { public static final String PARM_COPY_SOURCE = "source"; //$NON-NLS-1$ public static final String PARM_COPY_OVERWRITE = "overwrite"; //$NON-NLS-1$ public static final String PARM_OPTIONS = "options"; //$NON-NLS-1$ + public static final String PARM_ABSOLUTE_FILES = "absoluteFiles"; //$NON-NLS-1$ } diff --git a/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/ChmodAction.java b/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/ChmodAction.java index 321258d76..535e095e1 100644 --- a/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/ChmodAction.java +++ b/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/ChmodAction.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2008, 2010 IBM Corporation and others. + * Copyright (c) 2008, 2012 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -9,6 +9,7 @@ * Red Hat Incorporated - initial API and implementation * IBM Corporation - ongoing development * Cloudsmith Inc - ongoing development + * Landmark Graphics Corporation - bug 397183 *******************************************************************************/ package org.eclipse.equinox.internal.p2.touchpoint.natives.actions; @@ -25,23 +26,52 @@ public class ChmodAction extends ProvisioningAction { private static final String ACTION_CHMOD = "chmod"; //$NON-NLS-1$ private static final boolean WINDOWS = java.io.File.separatorChar == '\\'; + // target targetFile absoluteFiles + // Y Y Y can't set all these arguments + // Y Y N Y -> today, add the ability to specifty a list of fileNames + // Y N Y warning? targetFolder unecessary + // Y N N incorrect, missing targetFile + // N Y Y incorrect, target file can't be with absoluteFiles + // N Y N incorrect, missing the targetFolder + // N N Y Y + // N N N public IStatus execute(Map<String, Object> parameters) { + Object absoluteFiles = parameters.get(ActionConstants.PARM_ABSOLUTE_FILES); //String or String[] String targetDir = (String) parameters.get(ActionConstants.PARM_TARGET_DIR); - if (targetDir == null) - return Util.createError(NLS.bind(Messages.param_not_set, ActionConstants.PARM_TARGET_DIR, ACTION_CHMOD)); String targetFile = (String) parameters.get(ActionConstants.PARM_TARGET_FILE); - if (targetFile == null) + + if (targetFile != null && absoluteFiles != null) + return Util.createError(Messages.chmod_param_cant_be_set_together); + + if (targetDir != null && targetFile == null) return Util.createError(NLS.bind(Messages.param_not_set, ActionConstants.PARM_TARGET_FILE, ACTION_CHMOD)); + + if (targetDir == null && targetFile != null) + return Util.createError(NLS.bind(Messages.param_not_set, ActionConstants.PARM_TARGET_DIR, ACTION_CHMOD)); + String permissions = (String) parameters.get(ActionConstants.PARM_PERMISSIONS); if (permissions == null) return Util.createError(NLS.bind(Messages.param_not_set, ActionConstants.PARM_PERMISSIONS, ACTION_CHMOD)); String optionsString = (String) parameters.get(ActionConstants.PARM_OPTIONS); - // Check that file exist - File probe = new File(targetDir + IPath.SEPARATOR + targetFile); - if (!probe.exists()) - return Util.createError(NLS.bind(Messages.action_0_failed_file_1_doesNotExist, ACTION_CHMOD, probe.toString())); + String[] filesToProcess = absoluteFiles != null ? ((absoluteFiles instanceof String) ? new String[] {(String) absoluteFiles} : (String[]) absoluteFiles) : makeFilesAbsolute(targetDir, targetFile); + for (String fileToChmod : filesToProcess) { + // Check that file exist + File probe = new File(fileToChmod); + if (!probe.exists()) + return Util.createError(NLS.bind(Messages.action_0_failed_file_1_doesNotExist, ACTION_CHMOD, probe.toString())); + + doChmod(fileToChmod, permissions, optionsString); + } + + return Status.OK_STATUS; + } + private String[] makeFilesAbsolute(String targetDir, String targetFile) { + return new String[] {new String(targetDir + IPath.SEPARATOR + targetFile)}; + } + + private void doChmod(String fileToChmod, String permissions, String optionsString) { String options[] = null; if (optionsString != null) { ArrayList<String> collect = new ArrayList<String>(); @@ -63,8 +93,7 @@ public class ChmodAction extends ProvisioningAction { } } - chmod(targetDir, targetFile, permissions, options); - return Status.OK_STATUS; + chmod(fileToChmod, permissions, options); } public IStatus undo(Map<String, Object> parameters) { @@ -72,7 +101,7 @@ public class ChmodAction extends ProvisioningAction { return Status.OK_STATUS; } - public void chmod(String targetDir, String targetFile, String perms, String[] options) { + public void chmod(String fileToChmod, String perms, String[] options) { if (WINDOWS) return; Runtime r = Runtime.getRuntime(); @@ -86,7 +115,7 @@ public class ChmodAction extends ProvisioningAction { args[i++] = options[j]; } args[i++] = perms; - args[i] = targetDir + IPath.SEPARATOR + targetFile; + args[i] = fileToChmod; Process process = r.exec(args); readOffStream(process.getErrorStream()); readOffStream(process.getInputStream()); diff --git a/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/CleanupzipAction.java b/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/CleanupzipAction.java index 61a2acf3d..4c1414721 100644 --- a/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/CleanupzipAction.java +++ b/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/CleanupzipAction.java @@ -31,7 +31,7 @@ public class CleanupzipAction extends ProvisioningAction { } public IStatus undo(Map<String, Object> parameters) { - return UnzipAction.unzip(parameters, false); + return new UnzipAction().unzip(parameters, false); } public static IStatus cleanupzip(Map<String, Object> parameters, boolean restoreable) { diff --git a/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/UnzipAction.java b/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/UnzipAction.java index 0d87a5718..2c93bba32 100644 --- a/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/UnzipAction.java +++ b/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/actions/UnzipAction.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2008, 2010 IBM Corporation and others. + * Copyright (c) 2008, 2012 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -7,6 +7,7 @@ * * Contributors: * IBM Corporation - initial API and implementation + * Landmark Graphics Corporation - bug 397183 *******************************************************************************/ package org.eclipse.equinox.internal.p2.touchpoint.natives.actions; @@ -17,6 +18,7 @@ import org.eclipse.core.runtime.*; import org.eclipse.equinox.internal.p2.engine.Profile; import org.eclipse.equinox.internal.p2.touchpoint.natives.*; import org.eclipse.equinox.p2.engine.spi.ProvisioningAction; +import org.eclipse.equinox.p2.engine.spi.Value; import org.eclipse.equinox.p2.metadata.IArtifactKey; import org.eclipse.equinox.p2.metadata.IInstallableUnit; import org.eclipse.osgi.util.NLS; @@ -24,6 +26,7 @@ import org.eclipse.osgi.util.NLS; public class UnzipAction extends ProvisioningAction { public static final String ACTION_UNZIP = "unzip"; //$NON-NLS-1$ + private Value<String[]> result; public IStatus execute(Map<String, Object> parameters) { return unzip(parameters, true); @@ -40,7 +43,7 @@ public class UnzipAction extends ProvisioningAction { * @param restoreable - if the unzip should be backed up * @return status */ - public static IStatus unzip(Map<String, Object> parameters, boolean restoreable) { + public IStatus unzip(Map<String, Object> parameters, boolean restoreable) { String source = (String) parameters.get(ActionConstants.PARM_SOURCE); if (source == null) return Util.createError(NLS.bind(Messages.param_not_set, ActionConstants.PARM_SOURCE, ACTION_UNZIP)); @@ -68,6 +71,12 @@ public class UnzipAction extends ProvisioningAction { String excludePattern = (String) parameters.get(ActionConstants.PARM_EXCLUDE); File[] unzippedFiles = unzip(source, target, path, includePattern, excludePattern, store); + String[] filesAsString = new String[unzippedFiles.length]; + for (int i = 0; i < unzippedFiles.length; i++) { + filesAsString[i] = unzippedFiles[i].getAbsolutePath(); + } + result = new Value<String[]>(filesAsString); + StringBuffer unzippedFileNameBuffer = new StringBuffer(); for (int i = 0; i < unzippedFiles.length; i++) unzippedFileNameBuffer.append(unzippedFiles[i].getAbsolutePath()).append(ActionConstants.PIPE); @@ -96,4 +105,9 @@ public class UnzipAction extends ProvisioningAction { } return new File[0]; } + + @Override + public Value<String[]> getResult() { + return result; + } }
\ No newline at end of file diff --git a/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/messages.properties b/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/messages.properties index 1dbe1a176..1bbd40111 100644 --- a/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/messages.properties +++ b/bundles/org.eclipse.equinox.p2.touchpoint.natives/src/org/eclipse/equinox/internal/p2/touchpoint/natives/messages.properties @@ -33,6 +33,7 @@ action_0_failed_file_1_doesNotExist=The action {0} failed - file {1} does not ex artifact_not_available=The artifact for {0} is not available. unzipping=Extracting {0} param_not_set=The \"{0}\" parameter was not set in the \"{1}\" action. +chmod_param_cant_be_set_together=The parameters targetFile and absoluteFiles can't be set at the same time. artifact_repo_not_found=The artifact repository manager could not be found. could_not_obtain_download_cache=Could not obtain the download cache location. download_cache_not_writeable=Agent download cache not writeable: {0}. diff --git a/bundles/org.eclipse.equinox.p2.transport.ecf/.settings/.api_filters b/bundles/org.eclipse.equinox.p2.transport.ecf/.settings/.api_filters new file mode 100644 index 000000000..bd93c9575 --- /dev/null +++ b/bundles/org.eclipse.equinox.p2.transport.ecf/.settings/.api_filters @@ -0,0 +1,75 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<component id="org.eclipse.equinox.p2.transport.ecf" version="2">
+ <resource path="META-INF/MANIFEST.MF">
+ <filter id="923795461">
+ <message_arguments>
+ <message_argument value="1.1.0"/>
+ <message_argument value="1.0.100"/>
+ </message_arguments>
+ </filter>
+ </resource>
+ <resource path="src/org/eclipse/equinox/internal/p2/transport/ecf/Activator.java" type="org.eclipse.equinox.internal.p2.transport.ecf.Activator">
+ <filter id="305365105">
+ <message_arguments>
+ <message_argument value="org.eclipse.equinox.internal.p2.transport.ecf.Activator"/>
+ <message_argument value="org.eclipse.equinox.p2.transport.ecf_1.1.0"/>
+ </message_arguments>
+ </filter>
+ </resource>
+ <resource path="src/org/eclipse/equinox/internal/p2/transport/ecf/ECFTransportComponent.java" type="org.eclipse.equinox.internal.p2.transport.ecf.ECFTransportComponent">
+ <filter id="305365105">
+ <message_arguments>
+ <message_argument value="org.eclipse.equinox.internal.p2.transport.ecf.ECFTransportComponent"/>
+ <message_argument value="org.eclipse.equinox.p2.transport.ecf_1.1.0"/>
+ </message_arguments>
+ </filter>
+ </resource>
+ <resource path="src/org/eclipse/equinox/internal/p2/transport/ecf/FileInfoReader.java" type="org.eclipse.equinox.internal.p2.transport.ecf.FileInfoReader">
+ <filter id="305365105">
+ <message_arguments>
+ <message_argument value="org.eclipse.equinox.internal.p2.transport.ecf.FileInfoReader"/>
+ <message_argument value="org.eclipse.equinox.p2.transport.ecf_1.1.0"/>
+ </message_arguments>
+ </filter>
+ </resource>
+ <resource path="src/org/eclipse/equinox/internal/p2/transport/ecf/FileReader.java" type="org.eclipse.equinox.internal.p2.transport.ecf.FileReader">
+ <filter id="305365105">
+ <message_arguments>
+ <message_argument value="org.eclipse.equinox.internal.p2.transport.ecf.FileReader"/>
+ <message_argument value="org.eclipse.equinox.p2.transport.ecf_1.1.0"/>
+ </message_arguments>
+ </filter>
+ </resource>
+ <resource path="src/org/eclipse/equinox/internal/p2/transport/ecf/Messages.java" type="org.eclipse.equinox.internal.p2.transport.ecf.Messages">
+ <filter id="305365105">
+ <message_arguments>
+ <message_argument value="org.eclipse.equinox.internal.p2.transport.ecf.Messages"/>
+ <message_argument value="org.eclipse.equinox.p2.transport.ecf_1.1.0"/>
+ </message_arguments>
+ </filter>
+ </resource>
+ <resource path="src/org/eclipse/equinox/internal/p2/transport/ecf/RepositoryStatus.java" type="org.eclipse.equinox.internal.p2.transport.ecf.RepositoryStatus">
+ <filter id="305365105">
+ <message_arguments>
+ <message_argument value="org.eclipse.equinox.internal.p2.transport.ecf.RepositoryStatus"/>
+ <message_argument value="org.eclipse.equinox.p2.transport.ecf_1.1.0"/>
+ </message_arguments>
+ </filter>
+ </resource>
+ <resource path="src/org/eclipse/equinox/internal/p2/transport/ecf/RepositoryStatusHelper.java" type="org.eclipse.equinox.internal.p2.transport.ecf.RepositoryStatusHelper">
+ <filter id="305365105">
+ <message_arguments>
+ <message_argument value="org.eclipse.equinox.internal.p2.transport.ecf.RepositoryStatusHelper"/>
+ <message_argument value="org.eclipse.equinox.p2.transport.ecf_1.1.0"/>
+ </message_arguments>
+ </filter>
+ </resource>
+ <resource path="src/org/eclipse/equinox/internal/p2/transport/ecf/RepositoryTransport.java" type="org.eclipse.equinox.internal.p2.transport.ecf.RepositoryTransport">
+ <filter id="305365105">
+ <message_arguments>
+ <message_argument value="org.eclipse.equinox.internal.p2.transport.ecf.RepositoryTransport"/>
+ <message_argument value="org.eclipse.equinox.p2.transport.ecf_1.1.0"/>
+ </message_arguments>
+ </filter>
+ </resource>
+</component>
diff --git a/bundles/org.eclipse.equinox.p2.transport.ecf/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.p2.transport.ecf/META-INF/MANIFEST.MF index 04709e332..f5e77f0e9 100644 --- a/bundles/org.eclipse.equinox.p2.transport.ecf/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.equinox.p2.transport.ecf/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: %pluginName Bundle-SymbolicName: org.eclipse.equinox.p2.transport.ecf -Bundle-Version: 1.0.100.qualifier +Bundle-Version: 1.1.0.qualifier Bundle-RequiredExecutionEnvironment: J2SE-1.5, J2SE-1.4 Require-Bundle: org.eclipse.ecf;bundle-version="3.1.0", @@ -15,7 +15,7 @@ Require-Bundle: org.eclipse.ecf;bundle-version="3.1.0", Service-Component: OSGI-INF/ecfTransport.xml Bundle-Activator: org.eclipse.equinox.internal.p2.transport.ecf.Activator Bundle-ActivationPolicy: lazy -Export-Package: org.eclipse.equinox.internal.p2.transport.ecf +Export-Package: org.eclipse.equinox.internal.p2.transport.ecf;x-internal:=true Bundle-Vendor: %providerName Bundle-Localization: plugin Import-Package: org.eclipse.osgi.util;version="1.1.0", diff --git a/bundles/org.eclipse.equinox.p2.transport.ecf/pom.xml b/bundles/org.eclipse.equinox.p2.transport.ecf/pom.xml index 64d4babe3..042108132 100644 --- a/bundles/org.eclipse.equinox.p2.transport.ecf/pom.xml +++ b/bundles/org.eclipse.equinox.p2.transport.ecf/pom.xml @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> <project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns="http://maven.apache.org/POM/4.0.0" - xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <modelVersion>4.0.0</modelVersion> <parent> <artifactId>org.eclipse.equinox.p2-parent</artifactId> @@ -10,6 +10,25 @@ </parent> <groupId>org.eclipse</groupId> <artifactId>org.eclipse.equinox.p2.transport.ecf</artifactId> - <version>1.0.100-SNAPSHOT</version> + <version>1.1.0-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> + + <build> + <plugins> + <plugin> + <groupId>org.eclipse.tycho</groupId> + <artifactId>tycho-compiler-plugin</artifactId> + <configuration> + <!-- + matching apparently invalid Juno bundle + Minimal BREE according to META-INF/MENIFEST.MF should be J2SE-1.4, + yet Juno was compiled with class version 49.0, i.e. Java 5+ + Reported as https://bugs.eclipse.org/bugs/show_bug.cgi?id=386186 + --> + <source>1.5</source> + <target>1.5</target> + </configuration> + </plugin> + </plugins> + </build> </project> diff --git a/bundles/org.eclipse.equinox.p2.ui.discovery/pom.xml b/bundles/org.eclipse.equinox.p2.ui.discovery/pom.xml index 8f2c8b774..4a47b82ce 100644 --- a/bundles/org.eclipse.equinox.p2.ui.discovery/pom.xml +++ b/bundles/org.eclipse.equinox.p2.ui.discovery/pom.xml @@ -12,4 +12,15 @@ <artifactId>org.eclipse.equinox.p2.ui.discovery</artifactId> <version>1.0.0-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> + <build> + <plugins> + <plugin> + <groupId>org.eclipse.tycho</groupId> + <artifactId>target-platform-configuration</artifactId> + <configuration> + <executionEnvironment>J2SE-1.5</executionEnvironment> + </configuration> + </plugin> + </plugins> + </build> </project> diff --git a/bundles/org.eclipse.equinox.p2.ui.importexport/pom.xml b/bundles/org.eclipse.equinox.p2.ui.importexport/pom.xml index cd738cb32..d3403a369 100644 --- a/bundles/org.eclipse.equinox.p2.ui.importexport/pom.xml +++ b/bundles/org.eclipse.equinox.p2.ui.importexport/pom.xml @@ -10,6 +10,24 @@ </parent> <groupId>org.eclipse</groupId> <artifactId>org.eclipse.equinox.p2.ui.importexport</artifactId> - <version>1.0.1-SNAPSHOT</version> + <version>1.1.0-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> + + <build> + <plugins> + <plugin> + <groupId>org.eclipse.tycho</groupId> + <artifactId>tycho-compiler-plugin</artifactId> + <configuration> + <!-- + Minimal BREE according to META-INF/MENIFEST.MF should be CDC-1.1/Foundation-1.1, + which implies source=1.3 and target=1.2 and most likely is invalid. + + Project sources use generics, which requires source=1.5 to compile + --> + <source>1.5</source> + </configuration> + </plugin> + </plugins> + </build> </project> diff --git a/bundles/org.eclipse.equinox.p2.ui.sdk/src/org/eclipse/equinox/internal/p2/ui/sdk/ProvSDKUIActivator.java b/bundles/org.eclipse.equinox.p2.ui.sdk/src/org/eclipse/equinox/internal/p2/ui/sdk/ProvSDKUIActivator.java index 61ea6c7df..c6d6acd79 100644 --- a/bundles/org.eclipse.equinox.p2.ui.sdk/src/org/eclipse/equinox/internal/p2/ui/sdk/ProvSDKUIActivator.java +++ b/bundles/org.eclipse.equinox.p2.ui.sdk/src/org/eclipse/equinox/internal/p2/ui/sdk/ProvSDKUIActivator.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2007, 2010 IBM Corporation and others. + * Copyright (c) 2007, 2012 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -7,6 +7,7 @@ * * Contributors: * IBM Corporation - initial API and implementation + * Ericsson AB (Hamdan Msheik) - Bug 396420 - Control Install dialog through preference customization *******************************************************************************/ package org.eclipse.equinox.internal.p2.ui.sdk; @@ -120,7 +121,24 @@ public class ProvSDKUIActivator extends AbstractUIPlugin { } void updateWithPreferences(Policy policy) { - policy.setShowLatestVersionsOnly(getPreferenceStore().getBoolean(PreferenceConstants.PREF_SHOW_LATEST_VERSION)); + + IPreferenceStore store = getPreferenceStore(); + + String value = store.getString(PreferenceConstants.PREF_SHOW_LATEST_VERSION); + policy.setShowLatestVersionsOnly(!IPreferenceStore.STRING_DEFAULT_DEFAULT.equals(value) ? store.getBoolean(PreferenceConstants.PREF_SHOW_LATEST_VERSION) : policy.getShowLatestVersionsOnly()); + + value = store.getString(PreferenceConstants.PREF_HIDE_INSTALLED); + policy.setHideAlreadyInstalled(!IPreferenceStore.STRING_DEFAULT_DEFAULT.equals(value) ? store.getBoolean(PreferenceConstants.PREF_HIDE_INSTALLED) : policy.getHideAlreadyInstalled()); + + value = store.getString(PreferenceConstants.PREF_FILTER_ON_ENV); + policy.setFilterOnEnv(!IPreferenceStore.STRING_DEFAULT_DEFAULT.equals(value) ? store.getBoolean(PreferenceConstants.PREF_FILTER_ON_ENV) : policy.getFilterOnEnv()); + + value = store.getString(PreferenceConstants.PREF_CONTACT_ALL_SITES); + policy.setContactAllSites(!IPreferenceStore.STRING_DEFAULT_DEFAULT.equals(value) ? store.getBoolean(PreferenceConstants.PREF_CONTACT_ALL_SITES) : policy.getContactAllSites()); + + value = store.getString(PreferenceConstants.PREF_GROUP_BY_CATEGORY); + policy.setGroupByCategory(!IPreferenceStore.STRING_DEFAULT_DEFAULT.equals(value) ? store.getBoolean(PreferenceConstants.PREF_GROUP_BY_CATEGORY) : policy.getGroupByCategory()); + } /* diff --git a/bundles/org.eclipse.equinox.p2.ui.sdk/src/org/eclipse/equinox/internal/p2/ui/sdk/prefs/PreferenceConstants.java b/bundles/org.eclipse.equinox.p2.ui.sdk/src/org/eclipse/equinox/internal/p2/ui/sdk/prefs/PreferenceConstants.java index 144ac50eb..06f35c481 100644 --- a/bundles/org.eclipse.equinox.p2.ui.sdk/src/org/eclipse/equinox/internal/p2/ui/sdk/prefs/PreferenceConstants.java +++ b/bundles/org.eclipse.equinox.p2.ui.sdk/src/org/eclipse/equinox/internal/p2/ui/sdk/prefs/PreferenceConstants.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2007, 2010 IBM Corporation and others. + * Copyright (c) 2007, 2012 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -7,6 +7,7 @@ * * Contributors: * IBM Corporation - initial API and implementation + * Ericsson AB (Hamdan Msheik) - Bug 396420 - Control Install dialog through preference customization *******************************************************************************/ package org.eclipse.equinox.internal.p2.ui.sdk.prefs; @@ -17,6 +18,10 @@ public class PreferenceConstants { public static final String PREF_PAGE_PROVISIONING = "org.eclipse.equinox.internal.p2.ui.sdk.ProvisioningPreferencePage"; //$NON-NLS-1$ public static final String PREF_PAGE_SITES = "org.eclipse.equinox.internal.p2.ui.sdk.SitesPreferencePage"; //$NON-NLS-1$ public static final String PREF_SHOW_LATEST_VERSION = "showLatestVersion"; //$NON-NLS-1$ + public static final String PREF_GROUP_BY_CATEGORY = "groupByCategory"; //$NON-NLS-1$ + public static final String PREF_FILTER_ON_ENV = "filterOnEnv"; //$NON-NLS-1$ + public static final String PREF_CONTACT_ALL_SITES = "contactAllSites"; //$NON-NLS-1$ + public static final String PREF_HIDE_INSTALLED = "hideAlreadyInstalled"; //$NON-NLS-1$ public static final String PREF_OPEN_WIZARD_ON_ERROR_PLAN = "allowNonOKPlan"; //$NON-NLS-1$ public static final String PREF_LICENSE_DIGESTS = "licenseDigestList"; //$NON-NLS-1$ } diff --git a/bundles/org.eclipse.equinox.p2.ui.sdk/src/org/eclipse/equinox/internal/p2/ui/sdk/prefs/PreferenceInitializer.java b/bundles/org.eclipse.equinox.p2.ui.sdk/src/org/eclipse/equinox/internal/p2/ui/sdk/prefs/PreferenceInitializer.java index d1bfc9b15..9a3ce6ed9 100644 --- a/bundles/org.eclipse.equinox.p2.ui.sdk/src/org/eclipse/equinox/internal/p2/ui/sdk/prefs/PreferenceInitializer.java +++ b/bundles/org.eclipse.equinox.p2.ui.sdk/src/org/eclipse/equinox/internal/p2/ui/sdk/prefs/PreferenceInitializer.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2007, 2010 IBM Corporation and others. + * Copyright (c) 2007, 2012 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -7,6 +7,7 @@ * * Contributors: * IBM Corporation - initial API and implementation + * Ericsson AB (Hamdan Msheik) - Bug 396420 - Control Install dialog through preference customization *******************************************************************************/ package org.eclipse.equinox.internal.p2.ui.sdk.prefs; @@ -38,7 +39,12 @@ public class PreferenceInitializer extends AbstractPreferenceInitializer { // don't migrate everything. Some of the preferences moved to // another bundle. pref.put(PreferenceConstants.PREF_OPEN_WIZARD_ON_ERROR_PLAN, oldPref.get(PreferenceConstants.PREF_OPEN_WIZARD_ON_ERROR_PLAN, MessageDialogWithToggle.PROMPT)); - pref.putBoolean(PreferenceConstants.PREF_SHOW_LATEST_VERSION, oldPref.getBoolean(PreferenceConstants.PREF_SHOW_LATEST_VERSION, true)); + + // if the preference value associated with PREF_SHOW_LATEST_VERSION does not exist do not initialize it + String showLatestVersionString = oldPref.get(PreferenceConstants.PREF_SHOW_LATEST_VERSION, null); + if (showLatestVersionString != null) { + pref.putBoolean(PreferenceConstants.PREF_SHOW_LATEST_VERSION, Boolean.TRUE.toString().equalsIgnoreCase(showLatestVersionString)); + } pref.flush(); } } catch (BackingStoreException e) { diff --git a/bundles/org.eclipse.equinox.p2.ui/pom.xml b/bundles/org.eclipse.equinox.p2.ui/pom.xml index a7435f0c1..f2129a571 100644 --- a/bundles/org.eclipse.equinox.p2.ui/pom.xml +++ b/bundles/org.eclipse.equinox.p2.ui/pom.xml @@ -21,6 +21,6 @@ </parent> <groupId>org.eclipse</groupId> <artifactId>org.eclipse.equinox.p2.ui</artifactId> - <version>2.2.0-SNAPSHOT</version> + <version>2.2.100-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> </project> diff --git a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/ProvUI.java b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/ProvUI.java index e37c2ffbe..c194b8c94 100644 --- a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/ProvUI.java +++ b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/ProvUI.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2007, 2011 IBM Corporation and others. + * Copyright (c) 2007, 2012 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -7,6 +7,7 @@ * * Contributors: * IBM Corporation - initial API and implementation + * Ericsson AB (Hamdan Msheik) - Bug 396420 - Control Install dialog through preference customization *******************************************************************************/ package org.eclipse.equinox.internal.p2.ui; @@ -118,11 +119,15 @@ public class ProvUI { } + //Factory method returning a new instance of a IUViewQueryContext public static IUViewQueryContext getQueryContext(Policy policy) { IUViewQueryContext queryContext = new IUViewQueryContext(policy.getGroupByCategory() ? IUViewQueryContext.AVAILABLE_VIEW_BY_CATEGORY : IUViewQueryContext.AVAILABLE_VIEW_FLAT); - queryContext.setShowLatestVersionsOnly(policy.getShowLatestVersionsOnly()); queryContext.setShowInstallChildren(policy.getShowDrilldownRequirements()); queryContext.setShowProvisioningPlanChildren(policy.getShowDrilldownRequirements()); + + //among other things the 4 calls below are used to control the available software dialog (AvailableIUPage) + queryContext.setShowLatestVersionsOnly(policy.getShowLatestVersionsOnly()); + queryContext.setHideAlreadyInstalled(policy.getHideAlreadyInstalled()); queryContext.setUseCategories(policy.getGroupByCategory()); queryContext.setFilterOnEnv(policy.getFilterOnEnv()); return queryContext; diff --git a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/dialogs/AvailableIUsPage.java b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/dialogs/AvailableIUsPage.java index 84f5e932c..e72bcc4d1 100644 --- a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/dialogs/AvailableIUsPage.java +++ b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/dialogs/AvailableIUsPage.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2007, 2011 IBM Corporation and others. + * Copyright (c) 2007, 2012 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -9,6 +9,7 @@ * IBM Corporation - initial API and implementation * EclipseSource - ongoing development * Sonatype, Inc. - ongoing development + * Ericsson AB (Hamdan Msheik) - Bug 396420 - Control Install dialog through preference customization *******************************************************************************/ package org.eclipse.equinox.internal.p2.ui.dialogs; @@ -41,6 +42,7 @@ public class AvailableIUsPage extends ProvisioningWizardPage implements ISelecta private static final String SHOW_LATEST_VERSIONS_ONLY = "ShowLatestVersionsOnly"; //$NON-NLS-1$ private static final String HIDE_INSTALLED_IUS = "HideInstalledContent"; //$NON-NLS-1$ private static final String RESOLVE_ALL = "ResolveInstallWithAllSites"; //$NON-NLS-1$ + private static final String FILTER_ON_ENV = "FilterOnEnv"; //$NON-NLS-1$ private static final String NAME_COLUMN_WIDTH = "AvailableNameColumnWidth"; //$NON-NLS-1$ private static final String VERSION_COLUMN_WIDTH = "AvailableVersionColumnWidth"; //$NON-NLS-1$ private static final String LIST_WEIGHT = "AvailableListSashWeight"; //$NON-NLS-1$ @@ -353,12 +355,7 @@ public class AvailableIUsPage extends ProvisioningWizardPage implements ISelecta void updateQueryContext() { queryContext.setShowLatestVersionsOnly(showLatestVersionsCheckbox.getSelection()); - if (hideInstalledCheckbox.getSelection()) - queryContext.hideAlreadyInstalled(getProfileId()); - else { - queryContext.showAlreadyInstalled(); - queryContext.setInstalledProfileId(getProfileId()); - } + queryContext.setHideAlreadyInstalled(hideInstalledCheckbox.getSelection()); if (useCategoriesCheckbox.getSelection()) queryContext.setViewType(IUViewQueryContext.AVAILABLE_VIEW_BY_CATEGORY); else @@ -430,26 +427,22 @@ public class AvailableIUsPage extends ProvisioningWizardPage implements ISelecta IDialogSettings settings = ProvUIActivator.getDefault().getDialogSettings(); IDialogSettings section = settings.getSection(DIALOG_SETTINGS_SECTION); String value = null; - if (section != null) + + if (section != null) { value = section.get(RESOLVE_ALL); - // no section or no value in the section - if (value == null) - resolveAllCheckbox.setSelection(true); - else resolveAllCheckbox.setSelection(section.getBoolean(RESOLVE_ALL)); + } + // no section or no value in the section + if (value == null) { + resolveAllCheckbox.setSelection(getPolicy().getContactAllSites()); + } } } private void makeQueryContext() { - // Make a local query context that is based on the default. - IUViewQueryContext defaultQueryContext = ProvUI.getQueryContext(getPolicy()); - queryContext = new IUViewQueryContext(defaultQueryContext.getViewType()); - if (defaultQueryContext.getHideAlreadyInstalled()) { - queryContext.hideAlreadyInstalled(getProfileId()); - } else { - queryContext.setInstalledProfileId(getProfileId()); - } - queryContext.setShowLatestVersionsOnly(defaultQueryContext.getShowLatestVersionsOnly()); + queryContext = ProvUI.getQueryContext(getPolicy()); + queryContext.setInstalledProfileId(getProfileId()); + // Now check for saved away dialog settings IDialogSettings settings = ProvUIActivator.getDefault().getDialogSettings(); IDialogSettings section = settings.getSection(DIALOG_SETTINGS_SECTION); @@ -471,13 +464,11 @@ public class AvailableIUsPage extends ProvisioningWizardPage implements ISelecta queryContext.setShowLatestVersionsOnly(section.getBoolean(SHOW_LATEST_VERSIONS_ONLY)); // Hide installed content - boolean hideContent = section.getBoolean(HIDE_INSTALLED_IUS); - if (hideContent) - queryContext.hideAlreadyInstalled(getProfileId()); - else { - queryContext.setInstalledProfileId(getProfileId()); - queryContext.showAlreadyInstalled(); - } + if (section.get(HIDE_INSTALLED_IUS) != null) + queryContext.setHideAlreadyInstalled(section.getBoolean(HIDE_INSTALLED_IUS)); + + if (section.get(FILTER_ON_ENV) != null) + queryContext.setFilterOnEnv(section.getBoolean(FILTER_ON_ENV)); } } @@ -529,6 +520,7 @@ public class AvailableIUsPage extends ProvisioningWizardPage implements ISelecta section.put(HIDE_INSTALLED_IUS, hideInstalledCheckbox.getSelection()); if (resolveAllCheckbox != null) section.put(RESOLVE_ALL, resolveAllCheckbox.getSelection()); + section.put(FILTER_ON_ENV, filterOnEnvCheckBox.getSelection()); TreeColumn col = availableIUGroup.getCheckboxTreeViewer().getTree().getColumn(0); section.put(NAME_COLUMN_WIDTH, col.getWidth()); diff --git a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/model/QueriedElement.java b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/model/QueriedElement.java index 451cfc74b..a478e683f 100644 --- a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/model/QueriedElement.java +++ b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/model/QueriedElement.java @@ -66,10 +66,6 @@ public abstract class QueriedElement extends ProvElement { } public Object[] getChildren(Object o) { - Object[] cache = getCachedChildren(); - if (cache.length > 0) { - return getCachedChildren(); - } return fetchChildren(o, new NullProgressMonitor()); } @@ -163,9 +159,6 @@ public abstract class QueriedElement extends ProvElement { } public Object[] getCachedChildren() { - if (cachedChildren == null) { - return new Object[0]; - } return cachedChildren.toArray(); } diff --git a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/query/IUViewQueryContext.java b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/query/IUViewQueryContext.java index 8f36fb56c..3be0c0e72 100644 --- a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/query/IUViewQueryContext.java +++ b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/query/IUViewQueryContext.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2008, 2010 IBM Corporation and others. + * Copyright (c) 2008, 2012 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -7,6 +7,7 @@ * * Contributors: * IBM Corporation - initial API and implementation + * Ericsson AB (Hamdan Msheik) - Bug 396420 - Control Install dialog through preference customization *******************************************************************************/ package org.eclipse.equinox.internal.p2.ui.query; @@ -81,13 +82,8 @@ public class IUViewQueryContext { showLatestVersionsOnly = showLatest; } - public void hideAlreadyInstalled(String installedProfileId) { - profileId = installedProfileId; - hideAlreadyInstalled = true; - } - - public void showAlreadyInstalled() { - hideAlreadyInstalled = false; + public void setHideAlreadyInstalled(boolean hide) { + hideAlreadyInstalled = hide; } public boolean getHideAlreadyInstalled() { diff --git a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/Policy.java b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/Policy.java index 7ffab9d32..a944b5f94 100644 --- a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/Policy.java +++ b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/Policy.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2008, 2011 IBM Corporation and others. + * Copyright (c) 2008, 2012 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -7,6 +7,7 @@ * * Contributors: * IBM Corporation - initial API and implementation + * Ericsson AB (Hamdan Msheik) - Bug 396420 - Control Install dialog through preference customization *******************************************************************************/ package org.eclipse.equinox.p2.ui; @@ -98,6 +99,8 @@ public class Policy { private boolean groupByCategory = true; private boolean allowDrilldown = true; private boolean repositoriesVisible = true; + private boolean contactAllSites = true; + private boolean hideAlreadyInstalled = true; private boolean showLatestVersionsOnly = true; private int restartPolicy = RESTART_POLICY_PROMPT; private String repoPrefPageId; @@ -446,4 +449,52 @@ public class Policy { public void setUpdateDetailsPreferredSize(Point preferredSize) { this.wizardDetailsPreferredSize = preferredSize; } + + /** + * Get a boolean value indicating whether to contact all sites. + * + * @return <code>true</code> true if all sites need to be contacted, + * <code>false</code> otherwise. + * + * @since 4.3 + */ + public boolean getContactAllSites() { + return this.contactAllSites; + } + + /** + * Set a boolean indicating whether all sites need to be contacted. + * + * @param contactAll <code>true</code> if all sites need to be contacted, + * <code>false</code> otherwise. + * + * @since 4.3 + */ + public void setContactAllSites(boolean contactAll) { + this.contactAllSites = contactAll; + } + + /** + * Get a boolean value indicating whether to hide already installed units. + * + * @return <code>true</code> if already installed units are to be hidden, + * <code>false</code> otherwise. + * + * @since 4.3 + */ + public boolean getHideAlreadyInstalled() { + return this.hideAlreadyInstalled; + } + + /** + * Set a boolean indicating whether to hide already installed units. + * + * @param hide <code>true</code> if already installed units need to be hidden, + * <code>false</code> otherwise. + * + * @since 4.3 + */ + public void setHideAlreadyInstalled(boolean hide) { + this.hideAlreadyInstalled = hide; + } } diff --git a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/RepositoryManipulationPage.java b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/RepositoryManipulationPage.java index 73b63c7a8..914f56c2d 100644 --- a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/RepositoryManipulationPage.java +++ b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/p2/ui/RepositoryManipulationPage.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2007, 2012 IBM Corporation and others. + * Copyright (c) 2007, 2013 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -7,6 +7,7 @@ * * Contributors: * IBM Corporation - initial API and implementation + * Ericsson AB (Pascal Rapicault) - bug 398539 *******************************************************************************/ package org.eclipse.equinox.p2.ui; @@ -774,7 +775,7 @@ public class RepositoryManipulationPage extends PreferencePage implements IWorkb }; int retCode = dialog.open(); - if (retCode == Window.OK) { + if (retCode == Window.OK && dialog.getLocation() != null) { selected[0].setNickname(dialog.getName()); selected[0].setLocation(dialog.getLocation()); if (dialog.getLocation().equals(existingLocation)) { diff --git a/bundles/org.eclipse.equinox.simpleconfigurator.manipulator/src/org/eclipse/equinox/internal/simpleconfigurator/manipulator/SimpleConfiguratorManipulatorUtils.java b/bundles/org.eclipse.equinox.simpleconfigurator.manipulator/src/org/eclipse/equinox/internal/simpleconfigurator/manipulator/SimpleConfiguratorManipulatorUtils.java index 9e2ab18f1..c72ef3526 100644 --- a/bundles/org.eclipse.equinox.simpleconfigurator.manipulator/src/org/eclipse/equinox/internal/simpleconfigurator/manipulator/SimpleConfiguratorManipulatorUtils.java +++ b/bundles/org.eclipse.equinox.simpleconfigurator.manipulator/src/org/eclipse/equinox/internal/simpleconfigurator/manipulator/SimpleConfiguratorManipulatorUtils.java @@ -63,7 +63,13 @@ public class SimpleConfiguratorManipulatorUtils { Arrays.sort(simpleInfos, new Comparator() { public int compare(Object o1, Object o2) { if (o1 instanceof BundleInfo && o2 instanceof BundleInfo) { - return ((BundleInfo) o1).getSymbolicName().compareTo(((BundleInfo) o2).getSymbolicName()); + BundleInfo b1 = (BundleInfo) o1; + BundleInfo b2 = (BundleInfo) o2; + int bsnComparison = b1.getSymbolicName().compareTo(b2.getSymbolicName()); + if (bsnComparison != 0) + return bsnComparison; + // prefer latest version, see https://bugs.eclipse.org/363590 + return new Version(b2.getVersion()).compareTo(new Version(b1.getVersion())); } return 0; } |