pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From til...@apache.org
Subject svn commit: r1650806 - /pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/encoding/Type1Encoding.java
Date Sat, 10 Jan 2015 20:27:58 GMT
Author: tilman
Date: Sat Jan 10 20:27:58 2015
New Revision: 1650806

URL: http://svn.apache.org/r1650806
Log:
PDFBOX-2576: avoid inefficient use of keySet iterator instead of entrySet iterator

Modified:
    pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/encoding/Type1Encoding.java

Modified: pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/encoding/Type1Encoding.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/encoding/Type1Encoding.java?rev=1650806&r1=1650805&r2=1650806&view=diff
==============================================================================
--- pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/encoding/Type1Encoding.java
(original)
+++ pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/encoding/Type1Encoding.java
Sat Jan 10 20:27:58 2015
@@ -38,9 +38,9 @@ public class Type1Encoding extends Encod
         Map<Integer,String> codeToName = encoding.getCodeToNameMap();
         Type1Encoding enc = new Type1Encoding();
 
-        for (Integer code : codeToName.keySet())
+        for (Map.Entry<Integer, String> entry : codeToName.entrySet())
         {
-            enc.add(code, codeToName.get(code));
+            enc.add(entry.getKey(), entry.getValue());
         }
 
         return enc;



Mime
View raw message