mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-07-21 15:09:48 +08:00
fix FileResourceBug
This commit is contained in:
@@ -40,12 +40,12 @@ public abstract class AbstractRowHandler<T> implements RowHandler {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void handle(int sheetIndex, long rowIndex, List<Object> rowList) {
|
||||
public void handle(int sheetIndex, long rowIndex, List<Object> rowCells) {
|
||||
Assert.notNull(convertFunc);
|
||||
if (rowIndex < this.startRowIndex || rowIndex > this.endRowIndex) {
|
||||
return;
|
||||
}
|
||||
handleData(sheetIndex, rowIndex, convertFunc.callWithRuntimeException(rowList));
|
||||
handleData(sheetIndex, rowIndex, convertFunc.callWithRuntimeException(rowCells));
|
||||
}
|
||||
|
||||
/**
|
||||
|
@@ -42,11 +42,11 @@ public abstract class BeanRowHandler<T> extends AbstractRowHandler<T> {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void handle(int sheetIndex, long rowIndex, List<Object> rowList) {
|
||||
public void handle(int sheetIndex, long rowIndex, List<Object> rowCells) {
|
||||
if (rowIndex == this.headerRowIndex) {
|
||||
this.headerList = ListUtil.unmodifiable(Convert.toList(String.class, rowList));
|
||||
this.headerList = ListUtil.unmodifiable(Convert.toList(String.class, rowCells));
|
||||
return;
|
||||
}
|
||||
super.handle(sheetIndex, rowIndex, rowList);
|
||||
super.handle(sheetIndex, rowIndex, rowCells);
|
||||
}
|
||||
}
|
||||
|
@@ -39,11 +39,11 @@ public abstract class MapRowHandler extends AbstractRowHandler<Map<String, Objec
|
||||
}
|
||||
|
||||
@Override
|
||||
public void handle(int sheetIndex, long rowIndex, List<Object> rowList) {
|
||||
public void handle(int sheetIndex, long rowIndex, List<Object> rowCells) {
|
||||
if (rowIndex == this.headerRowIndex) {
|
||||
this.headerList = ListUtil.unmodifiable(Convert.toList(String.class, rowList));
|
||||
this.headerList = ListUtil.unmodifiable(Convert.toList(String.class, rowCells));
|
||||
return;
|
||||
}
|
||||
super.handle(sheetIndex, rowIndex, rowList);
|
||||
super.handle(sheetIndex, rowIndex, rowCells);
|
||||
}
|
||||
}
|
||||
|
@@ -17,9 +17,9 @@ public interface RowHandler {
|
||||
*
|
||||
* @param sheetIndex 当前Sheet序号
|
||||
* @param rowIndex 当前行号,从0开始计数
|
||||
* @param rowList 行数据列表
|
||||
* @param rowCells 行数据,每个Object表示一个单元格的值
|
||||
*/
|
||||
void handle(int sheetIndex, long rowIndex, List<Object> rowList);
|
||||
void handle(int sheetIndex, long rowIndex, List<Object> rowCells);
|
||||
|
||||
/**
|
||||
* 处理一个单元格的数据
|
||||
|
@@ -125,7 +125,7 @@ public class ExcelSaxReadTest {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void handle(int sheetIndex, long rowIndex, List<Object> rowList) {
|
||||
public void handle(int sheetIndex, long rowIndex, List<Object> rowCells) {
|
||||
|
||||
}
|
||||
}
|
||||
@@ -143,7 +143,7 @@ public class ExcelSaxReadTest {
|
||||
}
|
||||
|
||||
@Override
|
||||
public void handle(int sheetIndex, long rowIndex, List<Object> rowList) {
|
||||
public void handle(int sheetIndex, long rowIndex, List<Object> rowCells) {
|
||||
}
|
||||
}
|
||||
);
|
||||
|
Reference in New Issue
Block a user