jpountz commented on a change in pull request #881: LUCENE-8979: Code Cleanup: 
Use entryset for map iteration wherever possible. - part 2
URL: https://github.com/apache/lucene-solr/pull/881#discussion_r330579248
 
 

 ##########
 File path: 
lucene/benchmark/src/java/org/apache/lucene/benchmark/byTask/utils/Config.java
 ##########
 @@ -403,15 +404,15 @@ public String getColsValuesForValsByRound(int roundNum) {
       return "";
     }
     StringBuilder sb = new StringBuilder();
-    for (final String name : colForValByRound.keySet()) {
-      String colName = colForValByRound.get(name);
+    for (final Map.Entry<String, String> entry : colForValByRound.entrySet()) {
+      String colName = entry.getValue();
       String template = " " + colName;
       if (roundNum < 0) {
         // just append blanks
         sb.append(Format.formatPaddLeft("-", template));
       } else {
         // append actual values, for that round
-        Object a = valByRound.get(name);
+        Object a = valByRound.get(entry.getKey());
 
 Review comment:
   can you extract a variable?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org
For additional commands, e-mail: issues-h...@lucene.apache.org

Reply via email to