diff options
author | Andrey Loskutov | 2016-10-29 09:28:11 +0000 |
---|---|---|
committer | Andrey Loskutov | 2016-11-04 17:41:16 +0000 |
commit | 8ccd7fa0fae6e89d9a4d5df1c7165ba0112d4d59 (patch) | |
tree | 74e5ba25cbdd276ea14dc7aee6eb324c9619e0c2 /bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/mapping/DiffChangeEvent.java | |
parent | e1aab99c603e589eea162124fbb67f0b26f71e69 (diff) | |
download | eclipse.platform.team-8ccd7fa0fae6e89d9a4d5df1c7165ba0112d4d59.tar.gz eclipse.platform.team-8ccd7fa0fae6e89d9a4d5df1c7165ba0112d4d59.tar.xz eclipse.platform.team-8ccd7fa0fae6e89d9a4d5df1c7165ba0112d4d59.zip |
Bug 506732 - cleanup trailing spaces in team.core and team.ui
Change-Id: I6a92f3b0af9cd07df54bc2e37a8455a52eaf490c
Signed-off-by: Andrey Loskutov <loskutov@gmx.de>
Diffstat (limited to 'bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/mapping/DiffChangeEvent.java')
-rw-r--r-- | bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/mapping/DiffChangeEvent.java | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/mapping/DiffChangeEvent.java b/bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/mapping/DiffChangeEvent.java index c06aed66d..bd7fc2982 100644 --- a/bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/mapping/DiffChangeEvent.java +++ b/bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/mapping/DiffChangeEvent.java @@ -22,13 +22,13 @@ import org.eclipse.team.core.diff.*; public class DiffChangeEvent implements IDiffChangeEvent { private final IDiffTree tree; - + // List that accumulate changes // SyncInfo private Map changedResources = new HashMap(); private Set removedResources = new HashSet(); private Map addedResources = new HashMap(); - + private boolean reset = false; private List errors = new ArrayList(); @@ -68,7 +68,7 @@ public class DiffChangeEvent implements IDiffChangeEvent { public IDiff[] getChanges() { return (IDiff[]) changedResources.values().toArray(new IDiff[changedResources.size()]); } - + public void added(IDiff delta) { if (removedResources.contains(delta.getPath())) { // A removal followed by an addition is treated as a change @@ -78,19 +78,19 @@ public class DiffChangeEvent implements IDiffChangeEvent { addedResources.put(delta.getPath(), delta); } } - + public void removed(IPath path, IDiff delta) { if (changedResources.containsKey(path)) { // No use in reporting the change since it has subsequently been removed changedResources.remove(path); } else if (addedResources.containsKey(path)) { - // An addition followed by a removal can be dropped + // An addition followed by a removal can be dropped addedResources.remove(path); return; } removedResources.add(path); } - + public void changed(IDiff delta) { if (addedResources.containsKey(delta.getPath())) { // An addition followed by a change is an addition @@ -103,11 +103,11 @@ public class DiffChangeEvent implements IDiffChangeEvent { public void reset() { reset = true; } - + public boolean isReset() { return reset; } - + public boolean isEmpty() { return changedResources.isEmpty() && removedResources.isEmpty() && addedResources.isEmpty(); } |