mirror of https://github.com/apache/poi.git
minor perf issue
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1898086 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
7dbfc41dfb
commit
068cd83970
|
@ -626,10 +626,11 @@ public class XSSFRow implements Row, Comparable<XSSFRow> {
|
|||
* @param n the number of rows to move
|
||||
*/
|
||||
protected void shift(int n) {
|
||||
int rownum = getRowNum() + n;
|
||||
String msg = "Row[rownum=" + getRowNum() + "] contains cell(s) included in a multi-cell array formula. " +
|
||||
final int rownum = getRowNum();
|
||||
final int newRownum = rownum + n;
|
||||
String msg = "Row[rownum=" + rownum + "] contains cell(s) included in a multi-cell array formula. " +
|
||||
"You cannot change part of an array.";
|
||||
setRowNum(rownum);
|
||||
setRowNum(newRownum);
|
||||
for(Cell c : this){
|
||||
((XSSFCell)c).updateCellReferencesForShifting(msg);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue