修改异常包装策略:运行时异常不包装,只包装非运行时异常

This commit is contained in:
Looly
2023-08-08 19:03:56 +08:00
parent d5ac761f08
commit cd53378ae3
35 changed files with 155 additions and 92 deletions

View File

@@ -1,5 +1,6 @@
package org.dromara.hutool.poi.excel;
import org.dromara.hutool.core.io.IORuntimeException;
import org.dromara.hutool.poi.excel.cell.CellUtil;
import org.apache.poi.ss.usermodel.Cell;
import org.apache.poi.ss.usermodel.Row;
@@ -42,7 +43,7 @@ public class IssueI6MBS5Test {
CellUtil.setComment(cell, "commonText", "ascend", null);
workbook.write(Files.newOutputStream(file.toPath()));
} catch (final IOException e) {
throw new RuntimeException(e);
throw new IORuntimeException(e);
}
}
}