Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 261257 Details for
Bug 490770
Freeze report should mention compatible changes
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
Proposed patch including updated regression tests
eclipse.pde.ui.patch (text/plain), 44.77 KB, created by
Olivier Thomann
on 2016-04-26 10:59:38 EDT
(
hide
)
Description:
Proposed patch including updated regression tests
Filename:
MIME Type:
Creator:
Olivier Thomann
Created:
2016-04-26 10:59:38 EDT
Size:
44.77 KB
patch
obsolete
>diff --git a/apitools/org.eclipse.pde.api.tools.tests/src/org/eclipse/pde/api/tools/comparator/tests/BundlesDeltaTests.java b/apitools/org.eclipse.pde.api.tools.tests/src/org/eclipse/pde/api/tools/comparator/tests/BundlesDeltaTests.java >index b2f8731..491a722 100644 >--- a/apitools/org.eclipse.pde.api.tools.tests/src/org/eclipse/pde/api/tools/comparator/tests/BundlesDeltaTests.java >+++ b/apitools/org.eclipse.pde.api.tools.tests/src/org/eclipse/pde/api/tools/comparator/tests/BundlesDeltaTests.java >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2007, 2010 IBM Corporation and others. >+ * Copyright (c) 2007, 2016 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 >@@ -10,9 +10,6 @@ > *******************************************************************************/ > package org.eclipse.pde.api.tools.comparator.tests; > >-import junit.framework.Test; >-import junit.framework.TestSuite; >- > import org.eclipse.core.runtime.CoreException; > import org.eclipse.pde.api.tools.internal.provisional.VisibilityModifiers; > import org.eclipse.pde.api.tools.internal.provisional.comparator.ApiComparator; >@@ -21,6 +18,9 @@ > import org.eclipse.pde.api.tools.internal.provisional.model.IApiBaseline; > import org.eclipse.pde.api.tools.internal.provisional.model.IApiComponent; > import org.eclipse.pde.api.tools.internal.provisional.model.IApiTypeRoot; >+ >+import junit.framework.Test; >+import junit.framework.TestSuite; > > /** > * Delta tests for class >@@ -135,22 +135,16 @@ > IDelta delta = ApiComparator.compare(getBeforeState(), getAfterState(), VisibilityModifiers.ALL_VISIBILITIES, false, null); > assertNotNull("No delta", delta); //$NON-NLS-1$ > IDelta[] allLeavesDeltas = collectLeaves(delta); >- assertEquals("Wrong size", 2, allLeavesDeltas.length); //$NON-NLS-1$ >+ assertEquals("Wrong size", 1, allLeavesDeltas.length); //$NON-NLS-1$ > IDelta child = allLeavesDeltas[0]; >- assertEquals("Wrong kind", IDelta.ADDED, child.getKind()); //$NON-NLS-1$ >+ assertEquals("Wrong kind", IDelta.CHANGED, child.getKind()); //$NON-NLS-1$ > assertEquals("Wrong flag", IDelta.EXECUTION_ENVIRONMENT, child.getFlags()); //$NON-NLS-1$ > assertEquals("Wrong element type", IDelta.API_COMPONENT_ELEMENT_TYPE, child.getElementType()); //$NON-NLS-1$ > String[] arguments = child.getArguments(); >- assertEquals("Wrong size", 2, arguments.length); //$NON-NLS-1$ >- assertEquals("Wrong value", "J2SE-1.4", arguments[0]); //$NON-NLS-1$ //$NON-NLS-2$ >- assertTrue("Not compatible", DeltaProcessor.isCompatible(child)); //$NON-NLS-1$ >- child = allLeavesDeltas[1]; >- assertEquals("Wrong kind", IDelta.REMOVED, child.getKind()); //$NON-NLS-1$ >- assertEquals("Wrong flag", IDelta.EXECUTION_ENVIRONMENT, child.getFlags()); //$NON-NLS-1$ >- assertEquals("Wrong element type", IDelta.API_COMPONENT_ELEMENT_TYPE, child.getElementType()); //$NON-NLS-1$ >- arguments = child.getArguments(); >- assertEquals("Wrong size", 2, arguments.length); //$NON-NLS-1$ >+ assertEquals("Wrong size", 3, arguments.length); //$NON-NLS-1$ > assertEquals("Wrong value", "J2SE-1.5", arguments[0]); //$NON-NLS-1$ //$NON-NLS-2$ >+ assertEquals("Wrong value", "J2SE-1.4", arguments[1]); //$NON-NLS-1$ //$NON-NLS-2$ >+ assertEquals("Wrong value", "deltatest1_1.0.1", arguments[2]); //$NON-NLS-1$ //$NON-NLS-2$ > assertTrue("Not compatible", DeltaProcessor.isCompatible(child)); //$NON-NLS-1$ > } > >diff --git a/apitools/org.eclipse.pde.api.tools.tests/src/org/eclipse/pde/api/tools/comparator/tests/FieldDeltaTests.java b/apitools/org.eclipse.pde.api.tools.tests/src/org/eclipse/pde/api/tools/comparator/tests/FieldDeltaTests.java >index 855d96e..420c5ca 100644 >--- a/apitools/org.eclipse.pde.api.tools.tests/src/org/eclipse/pde/api/tools/comparator/tests/FieldDeltaTests.java >+++ b/apitools/org.eclipse.pde.api.tools.tests/src/org/eclipse/pde/api/tools/comparator/tests/FieldDeltaTests.java >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2007, 2010 IBM Corporation and others. >+ * Copyright (c) 2007, 2016 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 >@@ -30,9 +30,9 @@ > public class FieldDeltaTests extends DeltaTestSetup { > public static Test suite() { > return new TestSuite(FieldDeltaTests.class); >-// TestSuite suite = new TestSuite(FieldDeltaTests.class.getName()); >-// suite.addTest(new FieldDeltaTests("test75")); >-// return suite; >+ // TestSuite suite = new TestSuite(FieldDeltaTests.class.getName()); >+ // suite.addTest(new FieldDeltaTests("test78")); //$NON-NLS-1$ >+ // return suite; > } > > public FieldDeltaTests(String name) { >@@ -1809,6 +1809,31 @@ > assertEquals("Wrong element type", IDelta.FIELD_ELEMENT_TYPE, child.getElementType()); //$NON-NLS-1$ > assertTrue("Not compatible", DeltaProcessor.isCompatible(child)); //$NON-NLS-1$ > } >+ >+ /** >+ * https://bugs.eclipse.org/bugs/show_bug.cgi?id=490770 Non-compile time >+ * constant to compile time constant >+ */ >+ public void test78() { >+ deployBundles("test78"); //$NON-NLS-1$ >+ IApiBaseline before = getBeforeState(); >+ IApiBaseline after = getAfterState(); >+ IApiComponent beforeApiComponent = before.getApiComponent(BUNDLE_NAME); >+ assertNotNull("no api component", beforeApiComponent); //$NON-NLS-1$ >+ IApiComponent afterApiComponent = after.getApiComponent(BUNDLE_NAME); >+ assertNotNull("no api component", afterApiComponent); //$NON-NLS-1$ >+ IDelta delta = ApiComparator.compare(beforeApiComponent, afterApiComponent, before, after, >+ VisibilityModifiers.API, null); >+ assertNotNull("No delta", delta); //$NON-NLS-1$ >+ IDelta[] allLeavesDeltas = collectLeaves(delta); >+ assertEquals("Wrong size", 1, allLeavesDeltas.length); //$NON-NLS-1$ >+ IDelta child = allLeavesDeltas[0]; >+ assertEquals("Wrong kind", IDelta.ADDED, child.getKind()); //$NON-NLS-1$ >+ assertEquals("Wrong flag", IDelta.VALUE, child.getFlags()); //$NON-NLS-1$ >+ assertEquals("Wrong element type", IDelta.FIELD_ELEMENT_TYPE, child.getElementType()); //$NON-NLS-1$ >+ assertTrue("Not compatible", DeltaProcessor.isCompatible(child)); //$NON-NLS-1$ >+ } >+ > /** > * Check decrease field visibility - public to private > */ >diff --git a/apitools/org.eclipse.pde.api.tools.tests/tests-deltas/field/test78/after/X.java b/apitools/org.eclipse.pde.api.tools.tests/tests-deltas/field/test78/after/X.java >new file mode 100644 >index 0000000..92078aa >--- /dev/null >+++ b/apitools/org.eclipse.pde.api.tools.tests/tests-deltas/field/test78/after/X.java >@@ -0,0 +1,14 @@ >+/******************************************************************************* >+ * Copyright (c) 2016 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 >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * IBM Corporation - initial API and implementation >+ *******************************************************************************/ >+public class X { >+ public static final int i = 1; >+ public static final int j = Integer.valueOf(0).intValue(); >+} >diff --git a/apitools/org.eclipse.pde.api.tools.tests/tests-deltas/field/test78/before/X.java b/apitools/org.eclipse.pde.api.tools.tests/tests-deltas/field/test78/before/X.java >new file mode 100644 >index 0000000..6f871e0 >--- /dev/null >+++ b/apitools/org.eclipse.pde.api.tools.tests/tests-deltas/field/test78/before/X.java >@@ -0,0 +1,14 @@ >+/******************************************************************************* >+ * Copyright (c) 2016 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 >+ * http://www.eclipse.org/legal/epl-v10.html >+ * >+ * Contributors: >+ * IBM Corporation - initial API and implementation >+ *******************************************************************************/ >+public class X { >+ public static final int i = Integer.valueOf(1).intValue(); >+ public static final int j = Integer.valueOf(0).intValue(); >+} >diff --git a/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/comparator/ClassFileComparator.java b/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/comparator/ClassFileComparator.java >index 54160e3..aac0324 100644 >--- a/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/comparator/ClassFileComparator.java >+++ b/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/comparator/ClassFileComparator.java >@@ -1324,13 +1324,11 @@ > } > if (Flags.isDeprecated(access)) { > if (!Flags.isDeprecated(access2)) { >- this.addDelta(IDelta.FIELD_ELEMENT_TYPE, IDelta.REMOVED, IDelta.DEPRECATION, restrictions, access, access2, this.type1, name, new String[] { >- Util.getDescriptorName(this.type1), name }); >+ this.addDelta(IDelta.FIELD_ELEMENT_TYPE, IDelta.REMOVED, IDelta.DEPRECATION, restrictions, access, access2, this.type1, name, Util.getDescriptorName(this.type1) + '#' + name); > } > } else if (Flags.isDeprecated(access2)) { > // report delta - non-volatile to volatile >- this.addDelta(IDelta.FIELD_ELEMENT_TYPE, IDelta.ADDED, IDelta.DEPRECATION, restrictions, access, access2, this.type1, name, new String[] { >- Util.getDescriptorName(this.type1), name }); >+ this.addDelta(IDelta.FIELD_ELEMENT_TYPE, IDelta.ADDED, IDelta.DEPRECATION, restrictions, access, access2, this.type1, name, Util.getDescriptorName(this.type1) + '#' + name); > } > if (field.getConstantValue() != null) { > if (field2.getConstantValue() == null) { >@@ -1821,13 +1819,11 @@ > } > if (Flags.isDeprecated(access)) { > if (!Flags.isDeprecated(access2)) { >- this.addDelta(getElementType(method), IDelta.REMOVED, IDelta.DEPRECATION, restrictions, access, access2, this.type1, key, new String[] { >- Util.getDescriptorName(this.type1), methodDisplayName }); >+ this.addDelta(getElementType(method), IDelta.REMOVED, IDelta.DEPRECATION, restrictions, access, access2, this.type1, key, Util.getDescriptorName(this.type1) + '#' + methodDisplayName); > } > } else if (Flags.isDeprecated(access2)) { > // report delta - non-volatile to volatile >- this.addDelta(getElementType(method), IDelta.ADDED, IDelta.DEPRECATION, restrictions, access, access2, this.type1, key, new String[] { >- Util.getDescriptorName(this.type1), methodDisplayName }); >+ this.addDelta(getElementType(method), IDelta.ADDED, IDelta.DEPRECATION, restrictions, access, access2, this.type1, key, Util.getDescriptorName(this.type1) + '#' + methodDisplayName); > } > // check type parameters > String signature1 = method.getGenericSignature(); >diff --git a/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/comparator/Messages.java b/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/comparator/Messages.java >index 27a01a0..efa7e6e 100644 >--- a/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/comparator/Messages.java >+++ b/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/comparator/Messages.java >@@ -146,6 +146,8 @@ > return 95; > case IDelta.MINOR_VERSION: > return 96; >+ case IDelta.EXECUTION_ENVIRONMENT: >+ return 112; > default: > break; > } >diff --git a/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/comparator/compatible_delta_messages.properties b/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/comparator/compatible_delta_messages.properties >index 705a2a4..49efc62 100644 >--- a/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/comparator/compatible_delta_messages.properties >+++ b/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/comparator/compatible_delta_messages.properties >@@ -222,4 +222,6 @@ > # {0} given element > 110=The deprecation modifiers has been added to {0} > # {0} given element >-111=The deprecation modifiers has been removed from {0} >\ No newline at end of file >+111=The deprecation modifiers has been removed from {0} >+# {0} reference EE, {1} new EE, {2} component id >+112=The execution environment for {2} has been changed from {0} to {1} >\ No newline at end of file >diff --git a/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/provisional/comparator/ApiComparator.java b/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/provisional/comparator/ApiComparator.java >index 9a23c80..f2c8053 100644 >--- a/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/provisional/comparator/ApiComparator.java >+++ b/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/provisional/comparator/ApiComparator.java >@@ -267,21 +267,32 @@ > // check the EE first > Set<String> referenceEEs = Util.convertAsSet(referenceComponent.getExecutionEnvironments()); > Set<String> componentsEEs = Util.convertAsSet(component2.getExecutionEnvironments()); >- SubMonitor referencesLoopMonitor = localmonitor.split(1).setWorkRemaining(referenceEEs.size()); >- for (String currentEE : referenceEEs) { >- referencesLoopMonitor.split(1); >- if (!componentsEEs.remove(currentEE)) { >- globalDelta.add(new Delta(Util.getDeltaComponentVersionsId(referenceComponent), IDelta.API_COMPONENT_ELEMENT_TYPE, IDelta.REMOVED, IDelta.EXECUTION_ENVIRONMENT, RestrictionModifiers.NO_RESTRICTIONS, RestrictionModifiers.NO_RESTRICTIONS, 0, 0, null, referenceComponentId, new String[] { >+ >+ if (componentsEEs.size() == 1 && referenceEEs.size() == 1) { >+ String componentsEE = componentsEEs.iterator().next(); >+ String referenceEE = referenceEEs.iterator().next(); >+ if (!componentsEE.equals(referenceEE)) { >+ globalDelta.add(new Delta(Util.getDeltaComponentVersionsId(referenceComponent), IDelta.API_COMPONENT_ELEMENT_TYPE, IDelta.CHANGED, IDelta.EXECUTION_ENVIRONMENT, RestrictionModifiers.NO_RESTRICTIONS, RestrictionModifiers.NO_RESTRICTIONS, 0, 0, null, referenceComponentId, new String[] { >+ referenceEE, componentsEE, >+ Util.getComponentVersionsId(component2) })); >+ } >+ } else { >+ SubMonitor referencesLoopMonitor = localmonitor.split(1).setWorkRemaining(referenceEEs.size()); >+ for (String currentEE : referenceEEs) { >+ referencesLoopMonitor.split(1); >+ if (!componentsEEs.remove(currentEE)) { >+ globalDelta.add(new Delta(Util.getDeltaComponentVersionsId(referenceComponent), IDelta.API_COMPONENT_ELEMENT_TYPE, IDelta.REMOVED, IDelta.EXECUTION_ENVIRONMENT, RestrictionModifiers.NO_RESTRICTIONS, RestrictionModifiers.NO_RESTRICTIONS, 0, 0, null, referenceComponentId, new String[] { >+ currentEE, >+ Util.getComponentVersionsId(referenceComponent) })); >+ } >+ } >+ SubMonitor componentsLoopMonitor = localmonitor.split(1).setWorkRemaining(componentsEEs.size()); >+ for (String currentEE : componentsEEs) { >+ componentsLoopMonitor.split(1); >+ globalDelta.add(new Delta(Util.getDeltaComponentVersionsId(referenceComponent), IDelta.API_COMPONENT_ELEMENT_TYPE, IDelta.ADDED, IDelta.EXECUTION_ENVIRONMENT, RestrictionModifiers.NO_RESTRICTIONS, RestrictionModifiers.NO_RESTRICTIONS, 0, 0, null, referenceComponentId, new String[] { > currentEE, > Util.getComponentVersionsId(referenceComponent) })); > } >- } >- SubMonitor componentsLoopMonitor = localmonitor.split(1).setWorkRemaining(componentsEEs.size()); >- for (String currentEE : componentsEEs) { >- componentsLoopMonitor.split(1); >- globalDelta.add(new Delta(Util.getDeltaComponentVersionsId(referenceComponent), IDelta.API_COMPONENT_ELEMENT_TYPE, IDelta.ADDED, IDelta.EXECUTION_ENVIRONMENT, RestrictionModifiers.NO_RESTRICTIONS, RestrictionModifiers.NO_RESTRICTIONS, 0, 0, null, referenceComponentId, new String[] { >- currentEE, >- Util.getComponentVersionsId(referenceComponent) })); > } > return internalCompare(referenceComponent, component2, referenceBaseline, baseline, visibilityModifiers, globalDelta, localmonitor.split(1)); > } catch (CoreException e) { >diff --git a/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/util/Util.java b/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/util/Util.java >index 02723d2..2e85e27 100644 >--- a/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/util/Util.java >+++ b/apitools/org.eclipse.pde.api.tools/src/org/eclipse/pde/api/tools/internal/util/Util.java >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2007, 2013 IBM Corporation and others. >+ * Copyright (c) 2007, 2016 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 >@@ -29,6 +29,7 @@ > import java.io.StringReader; > import java.io.UnsupportedEncodingException; > import java.lang.reflect.Field; >+import java.lang.reflect.Modifier; > import java.nio.ByteBuffer; > import java.nio.CharBuffer; > import java.nio.charset.Charset; >@@ -141,6 +142,21 @@ > public static final String DOT_TAR_GZ = ".tar.gz"; //$NON-NLS-1$ > public static final String DOT_JAR = ".jar"; //$NON-NLS-1$ > public static final String DOT_ZIP = ".zip"; //$NON-NLS-1$ >+ public static Map<Integer, String> flagsNames = new HashMap<>(); >+ >+ static { >+ Field[] declaredFields = IDelta.class.getDeclaredFields(); >+ for (Field field : declaredFields) { >+ try { >+ if (Modifier.isFinal(field.getModifiers()) && Modifier.isStatic(field.getModifiers()) && Modifier.isPublic(field.getModifiers())) { >+ Integer value = Integer.valueOf(field.getInt(null)); >+ flagsNames.put(value, field.getName()); >+ } >+ } catch (IllegalAccessException e) { >+ // ignore >+ } >+ } >+ } > > public static final char VERSION_SEPARATOR = '('; > >@@ -687,6 +703,30 @@ > } > > /** >+ * Return an int value that represents the given flag value. Returns -1 if >+ * the flag value cannot be determined. >+ * >+ * @param flagName the given element type >+ * @return an int that represents the given flag value constant. >+ */ >+ public static int getDeltaFlagValue(String flagName) { >+ Class<IDelta> IDeltaClass = IDelta.class; >+ try { >+ Field field = IDeltaClass.getField(flagName); >+ return field.getInt(null); >+ } catch (SecurityException e) { >+ // ignore >+ } catch (IllegalArgumentException e) { >+ // ignore >+ } catch (NoSuchFieldException e) { >+ // ignore >+ } catch (IllegalAccessException e) { >+ // ignore >+ } >+ return -1; >+ } >+ >+ /** > * Return a string that represents the given element type Returns > * {@link #UNKNOWN_ELEMENT_KIND} if the element type cannot be determined. > * >@@ -729,141 +769,9 @@ > * @return a string that represents the given flags. > */ > public static String getDeltaFlagsName(int flags) { >- switch (flags) { >- case IDelta.ABSTRACT_TO_NON_ABSTRACT: >- return "ABSTRACT_TO_NON_ABSTRACT"; //$NON-NLS-1$ >- case IDelta.ANNOTATION_DEFAULT_VALUE: >- return "ANNOTATION_DEFAULT_VALUE"; //$NON-NLS-1$ >- case IDelta.API_COMPONENT: >- return "API_COMPONENT"; //$NON-NLS-1$ >- case IDelta.ARRAY_TO_VARARGS: >- return "ARRAY_TO_VARARGS"; //$NON-NLS-1$ >- case IDelta.CHECKED_EXCEPTION: >- return "CHECKED_EXCEPTION"; //$NON-NLS-1$ >- case IDelta.CLASS_BOUND: >- return "CLASS_BOUND"; //$NON-NLS-1$ >- case IDelta.CLINIT: >- return "CLINIT"; //$NON-NLS-1$ >- case IDelta.CONSTRUCTOR: >- return "CONSTRUCTOR"; //$NON-NLS-1$ >- case IDelta.CONTRACTED_SUPERINTERFACES_SET: >- return "CONTRACTED_SUPERINTERFACES_SET"; //$NON-NLS-1$ >- case IDelta.DECREASE_ACCESS: >- return "DECREASE_ACCESS"; //$NON-NLS-1$ >- case IDelta.ENUM_CONSTANT: >- return "ENUM_CONSTANT"; //$NON-NLS-1$ >- case IDelta.EXECUTION_ENVIRONMENT: >- return "EXECUTION_ENVIRONMENT"; //$NON-NLS-1$ >- case IDelta.EXPANDED_SUPERINTERFACES_SET: >- return "EXPANDED_SUPERINTERFACES_SET"; //$NON-NLS-1$ >- case IDelta.FIELD: >- return "FIELD"; //$NON-NLS-1$ >- case IDelta.FIELD_MOVED_UP: >- return "FIELD_MOVED_UP"; //$NON-NLS-1$ >- case IDelta.FINAL_TO_NON_FINAL: >- return "FINAL_TO_NON_FINAL"; //$NON-NLS-1$ >- case IDelta.FINAL_TO_NON_FINAL_NON_STATIC: >- return "FINAL_TO_NON_FINAL_NON_STATIC"; //$NON-NLS-1$ >- case IDelta.FINAL_TO_NON_FINAL_STATIC_CONSTANT: >- return "FINAL_TO_NON_FINAL_STATIC_CONSTANT"; //$NON-NLS-1$ >- case IDelta.FINAL_TO_NON_FINAL_STATIC_NON_CONSTANT: >- return "FINAL_TO_NON_FINAL_STATIC_NON_CONSTANT"; //$NON-NLS-1$ >- case IDelta.INCREASE_ACCESS: >- return "INCREASE_ACCESS"; //$NON-NLS-1$ >- case IDelta.INTERFACE_BOUND: >- return "INTERFACE_BOUND"; //$NON-NLS-1$ >- case IDelta.METHOD: >- return "METHOD"; //$NON-NLS-1$ >- case IDelta.METHOD_MOVED_UP: >- return "METHOD_MOVED_UP"; //$NON-NLS-1$ >- case IDelta.METHOD_WITH_DEFAULT_VALUE: >- return "METHOD_WITH_DEFAULT_VALUE"; //$NON-NLS-1$ >- case IDelta.METHOD_WITHOUT_DEFAULT_VALUE: >- return "METHOD_WITHOUT_DEFAULT_VALUE"; //$NON-NLS-1$ >- case IDelta.NATIVE_TO_NON_NATIVE: >- return "NATIVE_TO_NON_NATIVE"; //$NON-NLS-1$ >- case IDelta.NON_ABSTRACT_TO_ABSTRACT: >- return "NON_ABSTRACT_TO_ABSTRACT"; //$NON-NLS-1$ >- case IDelta.NON_FINAL_TO_FINAL: >- return "NON_FINAL_TO_FINAL"; //$NON-NLS-1$ >- case IDelta.NON_NATIVE_TO_NATIVE: >- return "NON_NATIVE_TO_NATIVE"; //$NON-NLS-1$ >- case IDelta.NON_STATIC_TO_STATIC: >- return "NON_STATIC_TO_STATIC"; //$NON-NLS-1$ >- case IDelta.NON_SYNCHRONIZED_TO_SYNCHRONIZED: >- return "NON_SYNCHRONIZED_TO_SYNCHRONIZED"; //$NON-NLS-1$ >- case IDelta.NON_TRANSIENT_TO_TRANSIENT: >- return "NON_TRANSIENT_TO_TRANSIENT"; //$NON-NLS-1$ >- case IDelta.OVERRIDEN_METHOD: >- return "OVERRIDEN_METHOD"; //$NON-NLS-1$ >- case IDelta.STATIC_TO_NON_STATIC: >- return "STATIC_TO_NON_STATIC"; //$NON-NLS-1$ >- case IDelta.SUPERCLASS: >- return "SUPERCLASS"; //$NON-NLS-1$ >- case IDelta.SYNCHRONIZED_TO_NON_SYNCHRONIZED: >- return "SYNCHRONIZED_TO_NON_SYNCHRONIZED"; //$NON-NLS-1$ >- case IDelta.TYPE_CONVERSION: >- return "TYPE_CONVERSION"; //$NON-NLS-1$ >- case IDelta.TRANSIENT_TO_NON_TRANSIENT: >- return "TRANSIENT_TO_NON_TRANSIENT"; //$NON-NLS-1$ >- case IDelta.TYPE: >- return "TYPE"; //$NON-NLS-1$ >- case IDelta.TYPE_ARGUMENTS: >- return "TYPE_ARGUMENTS"; //$NON-NLS-1$ >- case IDelta.TYPE_MEMBER: >- return "TYPE_MEMBER"; //$NON-NLS-1$ >- case IDelta.TYPE_PARAMETER: >- return "TYPE_PARAMETER"; //$NON-NLS-1$ >- case IDelta.TYPE_PARAMETER_NAME: >- return "TYPE_PARAMETER_NAME"; //$NON-NLS-1$ >- case IDelta.TYPE_PARAMETERS: >- return "TYPE_PARAMETERS"; //$NON-NLS-1$ >- case IDelta.TYPE_VISIBILITY: >- return "TYPE_VISIBILITY"; //$NON-NLS-1$ >- case IDelta.UNCHECKED_EXCEPTION: >- return "UNCHECKED_EXCEPTION"; //$NON-NLS-1$ >- case IDelta.VALUE: >- return "VALUE"; //$NON-NLS-1$ >- case IDelta.VARARGS_TO_ARRAY: >- return "VARARGS_TO_ARRAY"; //$NON-NLS-1$ >- case IDelta.RESTRICTIONS: >- return "RESTRICTIONS"; //$NON-NLS-1$ >- case IDelta.API_TYPE: >- return "API_TYPE"; //$NON-NLS-1$ >- case IDelta.NON_VOLATILE_TO_VOLATILE: >- return "NON_VOLATILE_TO_VOLATILE"; //$NON-NLS-1$ >- case IDelta.VOLATILE_TO_NON_VOLATILE: >- return "VOLATILE_TO_NON_VOLATILE"; //$NON-NLS-1$ >- case IDelta.MINOR_VERSION: >- return "MINOR_VERSION"; //$NON-NLS-1$ >- case IDelta.MAJOR_VERSION: >- return "MAJOR_VERSION"; //$NON-NLS-1$ >- case IDelta.API_FIELD: >- return "API_FIELD"; //$NON-NLS-1$ >- case IDelta.API_METHOD: >- return "API_METHOD"; //$NON-NLS-1$ >- case IDelta.API_CONSTRUCTOR: >- return "API_CONSTRUCTOR"; //$NON-NLS-1$ >- case IDelta.API_ENUM_CONSTANT: >- return "API_ENUM_CONSTANT"; //$NON-NLS-1$ >- case IDelta.API_METHOD_WITH_DEFAULT_VALUE: >- return "API_METHOD_WITH_DEFAULT_VALUE"; //$NON-NLS-1$ >- case IDelta.API_METHOD_WITHOUT_DEFAULT_VALUE: >- return "API_METHOD_WITHOUT_DEFAULT_VALUE"; //$NON-NLS-1$ >- case IDelta.TYPE_ARGUMENT: >- return "TYPE_ARGUMENT"; //$NON-NLS-1$ >- case IDelta.SUPER_INTERFACE_WITH_METHODS: >- return "SUPER_INTERFACE_WITH_METHODS"; //$NON-NLS-1$ >- case IDelta.REEXPORTED_API_TYPE: >- return "REEXPORTED_API_TYPE"; //$NON-NLS-1$ >- case IDelta.REEXPORTED_TYPE: >- return "REEXPORTED_TYPE"; //$NON-NLS-1$ >- case IDelta.METHOD_MOVED_DOWN: >- return "METHOD_MOVED_DOWN"; //$NON-NLS-1$ >- case IDelta.DEPRECATION: >- return "DEPRECATION"; //$NON-NLS-1$ >- default: >- break; >+ String fieldName = flagsNames.get(Integer.valueOf(flags)); >+ if (fieldName != null) { >+ return fieldName; > } > return UNKNOWN_FLAGS; > } >@@ -1371,7 +1279,7 @@ > /** > * Rewrite a parameter type signature with type erasure and using the > * parameterized type bounds lookup table. For example: >- * >+ * > * <pre> > * expand("QList<QE;>;", {"E" → "Ljava.lang.Object;"}) = "QList;" > * expand("QE;", {"E" → "Ljava.lang.Object;"}) = "Ljava.lang.Object;" >@@ -2343,8 +2251,18 @@ > default: > return arguments[0]; > } >+ case IDelta.EXECUTION_ENVIRONMENT: >+ StringBuilder builder = new StringBuilder(); >+ int i = 0; >+ for (String argument : arguments) { >+ if (i != 0) { >+ builder.append(','); >+ } >+ builder.append(argument); >+ i++; >+ } >+ return String.valueOf(builder); > default: >- break; > } > return EMPTY_STRING; > } >diff --git a/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/APIDeprecationReportConversionTask.java b/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/APIDeprecationReportConversionTask.java >index 6414eef..1f722eb 100644 >--- a/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/APIDeprecationReportConversionTask.java >+++ b/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/APIDeprecationReportConversionTask.java >@@ -89,6 +89,13 @@ > System.out.println("\t" + name + " = " + String.valueOf(attributes.getValue(name))); //$NON-NLS-1$ //$NON-NLS-2$ > } > >+ /* >+ * Only used in debug mode >+ */ >+ private void printFlagsAttribute(Attributes attributes, String name) { >+ System.out.println("\t" + name + " = " + String.valueOf(Util.getDeltaFlagsName(Integer.valueOf(attributes.getValue(name))))); //$NON-NLS-1$ //$NON-NLS-2$ >+ } >+ > @Override > public void startElement(String uri, String localName, String name, Attributes attributes) throws SAXException { > if (IApiXmlConstants.DELTA_ELEMENT_NAME.equals(name)) { >@@ -107,7 +114,7 @@ > printAttribute(attributes, IApiXmlConstants.ATTR_NAME_COMPATIBLE); > printAttribute(attributes, IApiXmlConstants.ATTR_NAME_COMPONENT_ID); > printAttribute(attributes, IApiXmlConstants.ATTR_NAME_ELEMENT_TYPE); >- printAttribute(attributes, IApiXmlConstants.ATTR_FLAGS); >+ printFlagsAttribute(attributes, IApiXmlConstants.ATTR_FLAGS); > printAttribute(attributes, IApiXmlConstants.ATTR_KEY); > printAttribute(attributes, IApiXmlConstants.ATTR_KIND); > printAttribute(attributes, IApiXmlConstants.ATTR_NAME_NEW_MODIFIERS); >diff --git a/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/APIFreezeReportConversionTask.java b/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/APIFreezeReportConversionTask.java >index 4b1b74b..cf09cb3 100644 >--- a/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/APIFreezeReportConversionTask.java >+++ b/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/APIFreezeReportConversionTask.java >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2008, 2013 IBM Corporation and others. >+ * Copyright (c) 2008, 2016 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 >@@ -27,10 +27,8 @@ > > import org.apache.tools.ant.BuildException; > import org.apache.tools.ant.Task; >-import org.eclipse.jdt.core.Signature; > import org.eclipse.osgi.util.NLS; > import org.eclipse.pde.api.tools.internal.IApiXmlConstants; >-import org.eclipse.pde.api.tools.internal.provisional.comparator.IDelta; > import org.eclipse.pde.api.tools.internal.util.Util; > import org.xml.sax.Attributes; > import org.xml.sax.SAXException; >@@ -53,6 +51,8 @@ > private Map<String, List<Entry>> map; > private String typename; > private int elementType; >+ private String message; >+ > /** > * String component id to ArrayList of String resolver error messages > */ >@@ -70,7 +70,7 @@ > if (IApiXmlConstants.ELEMENT_RESOLVER_ERRORS.equals(name)) { > isResolverSection = false; > } else if (IApiXmlConstants.DELTA_ELEMENT_NAME.equals(name)) { >- Entry entry = new Entry(this.flags, this.elementType, this.key, this.typename, this.arguments, this.kind); >+ Entry entry = new Entry(this.flags, this.elementType, this.key, this.typename, this.arguments, this.kind, this.message); > List<Entry> list = this.map.get(this.componentID); > if (list != null) { > list.add(entry); >@@ -103,6 +103,13 @@ > */ > private void printAttribute(Attributes attributes, String name) { > System.out.println("\t" + name + " = " + String.valueOf(attributes.getValue(name))); //$NON-NLS-1$ //$NON-NLS-2$ >+ } >+ >+ /* >+ * Only used in debug mode >+ */ >+ private void printFlagsAttribute(Attributes attributes, String name) { >+ System.out.println("\t" + name + " = " + String.valueOf(Util.getDeltaFlagsName(Integer.valueOf(attributes.getValue(name))))); //$NON-NLS-1$ //$NON-NLS-2$ > } > > @Override >@@ -139,13 +146,14 @@ > printAttribute(attributes, IApiXmlConstants.ATTR_NAME_COMPATIBLE); > printAttribute(attributes, IApiXmlConstants.ATTR_NAME_COMPONENT_ID); > printAttribute(attributes, IApiXmlConstants.ATTR_NAME_ELEMENT_TYPE); >- printAttribute(attributes, IApiXmlConstants.ATTR_FLAGS); >+ printFlagsAttribute(attributes, IApiXmlConstants.ATTR_FLAGS); > printAttribute(attributes, IApiXmlConstants.ATTR_KEY); > printAttribute(attributes, IApiXmlConstants.ATTR_KIND); > printAttribute(attributes, IApiXmlConstants.ATTR_NAME_NEW_MODIFIERS); > printAttribute(attributes, IApiXmlConstants.ATTR_NAME_OLD_MODIFIERS); > printAttribute(attributes, IApiXmlConstants.ATTR_RESTRICTIONS); > printAttribute(attributes, IApiXmlConstants.ATTR_NAME_TYPE_NAME); >+ printAttribute(attributes, IApiXmlConstants.ATTR_MESSAGE); > } > final String value = attributes.getValue(IApiXmlConstants.ATTR_NAME_COMPONENT_ID); > if (value == null) { >@@ -159,6 +167,7 @@ > this.typename = attributes.getValue(IApiXmlConstants.ATTR_NAME_TYPE_NAME); > this.key = attributes.getValue(IApiXmlConstants.ATTR_KEY); > this.kind = attributes.getValue(IApiXmlConstants.ATTR_KIND); >+ this.message = attributes.getValue(IApiXmlConstants.ATTR_MESSAGE); > } else if (IApiXmlConstants.ELEMENT_DELTA_MESSAGE_ARGUMENTS.equals(name)) { > if (this.argumentsList == null) { > this.argumentsList = new ArrayList<>(); >@@ -183,11 +192,12 @@ > String key; > String typeName; > String kind; >+ String message; > > private static final String ADDED = "ADDED"; //$NON-NLS-1$ > private static final String REMOVED = "REMOVED"; //$NON-NLS-1$ > >- public Entry(int flags, int elementType, String key, String typeName, String[] arguments, String kind) { >+ public Entry(int flags, int elementType, String key, String typeName, String[] arguments, String kind, String message) { > this.flags = flags; > this.key = key.replace('/', '.'); > if (typeName != null) { >@@ -196,113 +206,11 @@ > this.arguments = arguments; > this.kind = kind; > this.elementType = elementType; >+ this.message = message; > } > > public String getDisplayString() { >- StringBuffer buffer = new StringBuffer(); >- if (this.typeName != null && this.typeName.length() != 0) { >- buffer.append(this.typeName); >- switch (this.flags) { >- case IDelta.API_METHOD_WITH_DEFAULT_VALUE: >- case IDelta.API_METHOD_WITHOUT_DEFAULT_VALUE: >- case IDelta.API_METHOD: >- case IDelta.METHOD: >- case IDelta.METHOD_WITH_DEFAULT_VALUE: >- case IDelta.METHOD_WITHOUT_DEFAULT_VALUE: >- int indexOf = this.key.indexOf('('); >- if (indexOf == -1) { >- return null; >- } >- int index = indexOf; >- String selector = key.substring(0, index); >- String descriptor = key.substring(index, key.length()); >- buffer.append('#'); >- buffer.append(Signature.toString(descriptor, selector, null, false, true)); >- break; >- case IDelta.API_CONSTRUCTOR: >- case IDelta.CONSTRUCTOR: >- indexOf = key.indexOf('('); >- if (indexOf == -1) { >- return null; >- } >- index = indexOf; >- selector = key.substring(0, index); >- descriptor = key.substring(index, key.length()); >- buffer.append('#'); >- buffer.append(Signature.toString(descriptor, selector, null, false, false)); >- break; >- case IDelta.FIELD: >- case IDelta.API_FIELD: >- case IDelta.ENUM_CONSTANT: >- case IDelta.API_ENUM_CONSTANT: >- buffer.append('#'); >- buffer.append(this.key); >- break; >- case IDelta.TYPE_MEMBER: >- case IDelta.API_TYPE: >- case IDelta.REEXPORTED_TYPE: >- case IDelta.REEXPORTED_API_TYPE: >- buffer.append('.'); >- buffer.append(this.key); >- break; >- case IDelta.DEPRECATION: >- switch (this.elementType) { >- case IDelta.ANNOTATION_ELEMENT_TYPE: >- case IDelta.INTERFACE_ELEMENT_TYPE: >- case IDelta.ENUM_ELEMENT_TYPE: >- case IDelta.CLASS_ELEMENT_TYPE: >- buffer.append('.'); >- buffer.append(this.key); >- break; >- case IDelta.CONSTRUCTOR_ELEMENT_TYPE: >- indexOf = key.indexOf('('); >- if (indexOf == -1) { >- return null; >- } >- index = indexOf; >- selector = key.substring(0, index); >- descriptor = key.substring(index, key.length()); >- buffer.append('#'); >- buffer.append(Signature.toString(descriptor, selector, null, false, false)); >- break; >- case IDelta.METHOD_ELEMENT_TYPE: >- indexOf = key.indexOf('('); >- if (indexOf == -1) { >- return null; >- } >- index = indexOf; >- selector = key.substring(0, index); >- descriptor = key.substring(index, key.length()); >- buffer.append('#'); >- buffer.append(Signature.toString(descriptor, selector, null, false, true)); >- break; >- case IDelta.FIELD_ELEMENT_TYPE: >- buffer.append('#'); >- buffer.append(this.key); >- break; >- default: >- break; >- } >- break; >- default: >- break; >- } >- } else { >- switch (this.flags) { >- case IDelta.MAJOR_VERSION: >- buffer.append(NLS.bind(Messages.deltaReportTask_entry_major_version, this.arguments)); >- break; >- case IDelta.MINOR_VERSION: >- buffer.append(NLS.bind(Messages.deltaReportTask_entry_minor_version, this.arguments)); >- break; >- case IDelta.API_BASELINE_ELEMENT_TYPE: >- buffer.append(this.key); >- break; >- default: >- break; >- } >- } >- return CommonUtilsTask.convertToHtml(String.valueOf(buffer)); >+ return this.message; > } > > public String getDisplayKind() { >diff --git a/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/FilterListDeltaVisitor.java b/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/FilterListDeltaVisitor.java >index 913723b..24ce7d6 100644 >--- a/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/FilterListDeltaVisitor.java >+++ b/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/FilterListDeltaVisitor.java >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2008, 2013 IBM Corporation and others. >+ * Copyright (c) 2008, 2016 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 >@@ -101,6 +101,8 @@ > case IDelta.REEXPORTED_API_TYPE: > case IDelta.REEXPORTED_TYPE: > case IDelta.DEPRECATION: >+ case IDelta.ARRAY_TO_VARARGS: >+ case IDelta.VALUE: > buffer.append('#').append(delta.getKey()); > break; > case IDelta.MAJOR_VERSION: >@@ -110,7 +112,11 @@ > case IDelta.API_COMPONENT: > buffer.append(Util.getDeltaKindName(delta.getKind())).append('#').append(delta.getKey()); > break; >+ case IDelta.EXECUTION_ENVIRONMENT: >+ buffer.append(delta.getComponentId()).append(':').append(Util.getDeltaFlagsName(delta.getFlags())).append('=').append(delta.getArguments()[0]); >+ break; > default: >+ buffer.append('|').append(Util.getDeltaElementType(delta.getElementType())).append('|').append(Util.getDeltaKindName(delta.getKind())).append('|').append(Util.getDeltaFlagsName(delta.getFlags())).append('|').append(Util.getDeltaArgumentString(delta)); > break; > } > >@@ -145,27 +151,12 @@ > } > } > if ((this.flags & CHECK_OTHER) != 0) { >- switch (delta.getFlags()) { >- case IDelta.TYPE_MEMBER: >- case IDelta.METHOD: >- case IDelta.CONSTRUCTOR: >- case IDelta.ENUM_CONSTANT: >- case IDelta.METHOD_WITH_DEFAULT_VALUE: >- case IDelta.METHOD_WITHOUT_DEFAULT_VALUE: >- case IDelta.FIELD: >- case IDelta.TYPE: >- case IDelta.API_TYPE: >- case IDelta.API_METHOD: >- case IDelta.API_FIELD: >- case IDelta.API_CONSTRUCTOR: >- case IDelta.API_ENUM_CONSTANT: >- case IDelta.REEXPORTED_TYPE: >- if (!checkExclude(delta)) { >- super.processLeafDelta(delta); >- } >- break; >- default: >- break; >+ if (delta.getFlags() == IDelta.OVERRIDEN_METHOD && delta.getElementType() == IDelta.INTERFACE_ELEMENT_TYPE) { >+ // org.eclipse.core.resources.IWorkspaceRunnable#run(..) >+ return; >+ } >+ if (!checkExclude(delta)) { >+ super.processLeafDelta(delta); > } > } > } else if (Flags.isProtected(modifiers) && !RestrictionModifiers.isExtendRestriction(delta.getCurrentRestrictions())) { >@@ -181,53 +172,20 @@ > } > } > if ((this.flags & CHECK_OTHER) != 0) { >- switch (delta.getFlags()) { >- case IDelta.TYPE_MEMBER: >- case IDelta.METHOD: >- case IDelta.CONSTRUCTOR: >- case IDelta.ENUM_CONSTANT: >- case IDelta.FIELD: >- case IDelta.TYPE: >- case IDelta.API_TYPE: >- case IDelta.API_METHOD: >- case IDelta.API_FIELD: >- case IDelta.API_CONSTRUCTOR: >- case IDelta.API_ENUM_CONSTANT: >- case IDelta.REEXPORTED_TYPE: >- if (!checkExclude(delta)) { >- super.processLeafDelta(delta); >- } >- break; >- default: >- break; >+ if (!checkExclude(delta)) { >+ super.processLeafDelta(delta); > } > } >- } >- if (delta.getElementType() == IDelta.API_BASELINE_ELEMENT_TYPE && ((this.flags & CHECK_OTHER) != 0)) { >- switch (delta.getKind()) { >- case IDelta.ADDED: >- if (delta.getFlags() == IDelta.API_COMPONENT) { >- if (!checkExclude(delta)) { >- super.processLeafDelta(delta); >- } >- } >- break; >- default: >- break; >+ } else if ((this.flags & CHECK_OTHER) != 0) { >+ if (!checkExclude(delta)) { >+ super.processLeafDelta(delta); > } > } > break; > case IDelta.CHANGED: > if ((this.flags & CHECK_OTHER) != 0) { >- switch (delta.getFlags()) { >- case IDelta.MAJOR_VERSION: >- case IDelta.MINOR_VERSION: >- if (!checkExclude(delta)) { >- super.processLeafDelta(delta); >- } >- break; >- default: >- break; >+ if (!checkExclude(delta)) { >+ super.processLeafDelta(delta); > } > } > break; >@@ -242,73 +200,20 @@ > default: > break; > } >+ } else if ((this.flags & CHECK_OTHER) != 0) { >+ if (!checkExclude(delta)) { >+ super.processLeafDelta(delta); >+ } > } > break; > default: > break; > } > } else if ((this.flags & CHECK_OTHER) != 0) { >- switch (delta.getKind()) { >- case IDelta.ADDED: >- switch (delta.getFlags()) { >- case IDelta.TYPE_MEMBER: >- case IDelta.METHOD: >- case IDelta.CONSTRUCTOR: >- case IDelta.ENUM_CONSTANT: >- case IDelta.METHOD_WITH_DEFAULT_VALUE: >- case IDelta.METHOD_WITHOUT_DEFAULT_VALUE: >- case IDelta.FIELD: >- case IDelta.TYPE: >- case IDelta.API_TYPE: >- case IDelta.API_METHOD: >- case IDelta.API_FIELD: >- case IDelta.API_CONSTRUCTOR: >- case IDelta.API_ENUM_CONSTANT: >- case IDelta.REEXPORTED_TYPE: >- if (Util.isVisible(delta.getNewModifiers())) { >- if (!checkExclude(delta)) { >- super.processLeafDelta(delta); >- } >- } >- break; >- default: >- break; >- } >- break; >- case IDelta.REMOVED: >- switch (delta.getFlags()) { >- case IDelta.TYPE_MEMBER: >- case IDelta.METHOD: >- case IDelta.CONSTRUCTOR: >- case IDelta.ENUM_CONSTANT: >- case IDelta.METHOD_WITH_DEFAULT_VALUE: >- case IDelta.METHOD_WITHOUT_DEFAULT_VALUE: >- case IDelta.FIELD: >- case IDelta.TYPE: >- case IDelta.API_TYPE: >- case IDelta.API_METHOD: >- case IDelta.API_FIELD: >- case IDelta.API_CONSTRUCTOR: >- case IDelta.API_ENUM_CONSTANT: >- case IDelta.REEXPORTED_API_TYPE: >- case IDelta.REEXPORTED_TYPE: >- if (Util.isVisible(delta.getOldModifiers())) { >- if (!checkExclude(delta)) { >- super.processLeafDelta(delta); >- } >- } >- break; >- case IDelta.API_COMPONENT: >- if (!checkExclude(delta)) { >- super.processLeafDelta(delta); >- } >- break; >- default: >- break; >- } >- break; >- default: >- break; >+ if (Util.isVisible(delta.getNewModifiers())) { >+ if (!checkExclude(delta)) { >+ super.processLeafDelta(delta); >+ } > } > } > } >diff --git a/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/Messages.java b/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/Messages.java >index dd59e81..ef44633 100644 >--- a/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/Messages.java >+++ b/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/Messages.java >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2008, 2013 IBM Corporation and others. >+ * Copyright (c) 2008, 2016 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 >@@ -32,6 +32,8 @@ > public static String deltaReportTask_missingXmlFile; > public static String deltaReportTask_xmlFileLocationMustBeAFile; > public static String deltaReportTask_hmlFileLocationMustBeAFile; >+ public static String deltaReportTask_compile_time_constant; >+ public static String deltaReportTask_entry_execution_environment; > > public static String fullReportTask_bundlesheader; > public static String fullReportTask_bundlesentry_even; >diff --git a/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/messages.properties b/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/messages.properties >index c7e87d0..3705e7e 100644 >--- a/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/messages.properties >+++ b/apitools/org.eclipse.pde.api.tools/src_ant/org/eclipse/pde/api/tools/internal/tasks/messages.properties >@@ -1,5 +1,5 @@ > ############################################################################### >-# Copyright (c) 2008, 2013 IBM Corporation and others. >+# Copyright (c) 2008, 2016 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 >@@ -47,6 +47,8 @@ > deltaReportTask_xmlFileLocationMustBeAFile=The xml report file {0} must be a file and not a directory > deltaReportTask_hmlFileLocationMustBeAFile=The html report file {0} must be a file and not a directory > deltaReportTask_couldNotCreateSAXParser=Could not create a sax parser >+deltaReportTask_compile_time_constant=Compile-time constant >+deltaReportTask_entry_execution_environment=Execution Environment > missing_xml_files_location=The directory that contains xml reports must be specified > invalid_directory_name=''{0}'' is not a valid directory name > could_not_create_sax_parser=Could not create a sax parser
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 490770
:
260814
|
261257
|
261264
|
261265
|
261404