Browse Source

Use entrySet() instead of keySet()

The value was accessed every time in the loop body with get(),
so use the more efficient entrySet().

Change-Id: I91d90cbd0b0d03ca4a3db986c58b8d80d80f40a4
stable-0.10
Robin Stocker 14 years ago
parent
commit
3b44b22609
  1. 5
      org.eclipse.jgit/src/org/eclipse/jgit/api/MergeResult.java

5
org.eclipse.jgit/src/org/eclipse/jgit/api/MergeResult.java

@ -169,8 +169,9 @@ public class MergeResult {
this.mergeStrategy = mergeStrategy;
this.description = description;
if (lowLevelResults != null)
for (String path : lowLevelResults.keySet())
addConflict(path, lowLevelResults.get(path));
for (Map.Entry<String, org.eclipse.jgit.merge.MergeResult<?>> result : lowLevelResults
.entrySet())
addConflict(result.getKey(), result.getValue());
}
/**

Loading…
Cancel
Save