Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/org.eclipse.emf.compare.uml2/src/org/eclipse/emf/compare/uml2/internal/postprocessor/AbstractUMLChangeFactory.java')
-rw-r--r--plugins/org.eclipse.emf.compare.uml2/src/org/eclipse/emf/compare/uml2/internal/postprocessor/AbstractUMLChangeFactory.java7
1 files changed, 4 insertions, 3 deletions
diff --git a/plugins/org.eclipse.emf.compare.uml2/src/org/eclipse/emf/compare/uml2/internal/postprocessor/AbstractUMLChangeFactory.java b/plugins/org.eclipse.emf.compare.uml2/src/org/eclipse/emf/compare/uml2/internal/postprocessor/AbstractUMLChangeFactory.java
index f7632e8ec..e6b74e9bc 100644
--- a/plugins/org.eclipse.emf.compare.uml2/src/org/eclipse/emf/compare/uml2/internal/postprocessor/AbstractUMLChangeFactory.java
+++ b/plugins/org.eclipse.emf.compare.uml2/src/org/eclipse/emf/compare/uml2/internal/postprocessor/AbstractUMLChangeFactory.java
@@ -556,7 +556,7 @@ public abstract class AbstractUMLChangeFactory extends AbstractChangeFactory {
* The difference.
* @return True if it is related to a CHANGE in an ADD/DELETE.
*/
- private boolean isChangeOnAddOrDelete(Diff input) {
+ protected boolean isChangeOnAddOrDelete(Diff input) {
if (getRelatedExtensionKind(input) == DifferenceKind.CHANGE) {
final Comparison comparison = input.getMatch().getComparison();
final EObject discriminant = getDiscriminant(input);
@@ -581,8 +581,9 @@ public abstract class AbstractUMLChangeFactory extends AbstractChangeFactory {
*/
private boolean isChangeOnAddOrDelete(Diff input, final Comparison comparison, final EObject discriminant) {
boolean result = false;
- if (Iterables.any(comparison.getMatch(discriminant).getDifferences(),
- instanceOf(ResourceAttachmentChange.class))) {
+ Match match = comparison.getMatch(discriminant);
+ if (match != null
+ && Iterables.any(match.getDifferences(), instanceOf(ResourceAttachmentChange.class))) {
result = true;
}
if (!result) {

Back to the top