You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@poi.apache.org by on...@apache.org on 2016/07/04 18:43:46 UTC
svn commit: r1751369 -
/poi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFTable.java
Author: onealj
Date: Mon Jul 4 18:43:45 2016
New Revision: 1751369
URL: http://svn.apache.org/viewvc?rev=1751369&view=rev
Log:
pre for-each iteration over for index iteration
Modified:
poi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFTable.java
Modified: poi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFTable.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFTable.java?rev=1751369&r1=1751368&r2=1751369&view=diff
==============================================================================
--- poi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFTable.java (original)
+++ poi/trunk/src/ooxml/java/org/apache/poi/xssf/usermodel/XSSFTable.java Mon Jul 4 18:43:45 2016
@@ -293,8 +293,8 @@ public class XSSFTable extends POIXMLDoc
}
/**
- * @since POI 3.15 beta 3
- */
+ * @since POI 3.15 beta 3
+ */
private void setCellReferences() {
String ref = ctTable.getRef();
if (ref != null) {
@@ -399,9 +399,11 @@ public class XSSFTable extends POIXMLDoc
final int count = getTableColumns().length;
columnMap = new HashMap<String, Integer>(count * 3 / 2);
- for (int i=0; i < count; i++) {
- String columnName = getTableColumns()[i].getName();
+ int i = 0;
+ for (CTTableColumn column : getTableColumns()) {
+ String columnName = column.getName();
columnMap.put(caseInsensitive(columnName), i);
+ i++;
}
}
// Table column names with special characters need a single quote escape
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@poi.apache.org
For additional commands, e-mail: commits-help@poi.apache.org