commit | ff7f0d838fb6cd3a7091dd3365d0ae3d2417b69b | [log] [tgz] |
---|---|---|
author | Lars Vogel <Lars.Vogel@vogella.com> | Wed May 05 11:27:59 2021 +0200 |
committer | Lars Vogel <Lars.Vogel@vogella.com> | Mon May 10 13:48:43 2021 -0400 |
tree | 0dcac87eb77144d97511fbfb8c7bd74466654546 | |
parent | f97e0374e552bf072482a60d176dc230071a1006 [diff] |
Use JDT static inner class clean up for team.core This ticket uses and tests the "Use static inner class" cleanup feature: - It reviews the feature - It reduces the memory consumption as it avoids the pointer to the outer class Example: Before: public class Outer { public class InnerClass { int i; public boolean anotherMethod() { return true; } } } After: public class Outer { public static class InnerClass { int i; public boolean anotherMethod() { return true; } } } Change-Id: I3982b15f62d5e42da12f3ee114712002655651c7 Signed-off-by: Lars Vogel <Lars.Vogel@vogella.com> Reviewed-on: https://git.eclipse.org/r/c/platform/eclipse.platform.team/+/180222 Tested-by: Platform Bot <platform-bot@eclipse.org>
diff --git a/bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/mapping/ScopeManagerEventHandler.java b/bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/mapping/ScopeManagerEventHandler.java index 95ac2ef..d658266 100644 --- a/bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/mapping/ScopeManagerEventHandler.java +++ b/bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/mapping/ScopeManagerEventHandler.java
@@ -33,7 +33,7 @@ private Set<ResourceMapping> toRefresh = new HashSet<>(); private ISynchronizationScopeManager manager; - class ResourceMappingEvent extends Event { + static class ResourceMappingEvent extends Event { private final ResourceMapping[] mappings; public ResourceMappingEvent(ResourceMapping[] mappings) { super(REFRESH);
diff --git a/bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/subscribers/BatchingLock.java b/bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/subscribers/BatchingLock.java index 0c4939d..63a569c 100644 --- a/bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/subscribers/BatchingLock.java +++ b/bundles/org.eclipse.team.core/src/org/eclipse/team/internal/core/subscribers/BatchingLock.java
@@ -59,7 +59,7 @@ } }; - public class ThreadInfo { + public static class ThreadInfo { private Set<IResource> changedResources = new HashSet<>(); private IFlushOperation operation; private List<ISchedulingRule> rules = new ArrayList<>();