Skip to content

Commit

Permalink
修改项目名Easyexcel改名FastExcel同时兼容老的Easyexcel
Browse files Browse the repository at this point in the history
  • Loading branch information
Chat2DB-Pro committed Nov 27, 2024
1 parent 88089db commit aa5fe56
Show file tree
Hide file tree
Showing 8 changed files with 21 additions and 11 deletions.
4 changes: 2 additions & 2 deletions fastexcel-core/src/main/java/cn/idev/excel/EasyExcel.java
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
package cn.idev.excel;

/**
* This is actually {@link EasyExcelFactory}, and short names look better.
* This is actually {@link FastExcelFactory}, and short names look better.
*
* @author jipengfei
*/
public class EasyExcel extends EasyExcelFactory {}
public class EasyExcel extends FastExcelFactory {}
10 changes: 10 additions & 0 deletions fastexcel-core/src/main/java/cn/idev/excel/FastExcel.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
package cn.idev.excel;

/**
* This is actually {@link FastExcelFactory}, and short names look better.
*
* @author jipengfei
*/
public class FastExcel extends FastExcelFactory {

}
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
*
* @author jipengfei
*/
public class EasyExcelFactory {
public class FastExcelFactory {

/**
* Build excel the write
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public ReadSheet build() {
*/
public void doRead() {
if (excelReader == null) {
throw new ExcelGenerateException("Must use 'EasyExcelFactory.read().sheet()' to call this method");
throw new ExcelGenerateException("Must use 'FastExcelFactory.read().sheet()' to call this method");
}
excelReader.read(build());
excelReader.finish();
Expand All @@ -73,7 +73,7 @@ public void doRead() {
*/
public <T> List<T> doReadSync() {
if (excelReader == null) {
throw new ExcelAnalysisException("Must use 'EasyExcelFactory.read().sheet()' to call this method");
throw new ExcelAnalysisException("Must use 'FastExcelFactory.read().sheet()' to call this method");
}
SyncReadListener syncReadListener = new SyncReadListener();
registerReadListener(syncReadListener);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public WriteSheet build() {

public void doWrite(Collection<?> data) {
if (excelWriter == null) {
throw new ExcelGenerateException("Must use 'EasyExcelFactory.write().sheet()' to call this method");
throw new ExcelGenerateException("Must use 'FastExcelFactory.write().sheet()' to call this method");
}
excelWriter.write(data, build());
excelWriter.finish();
Expand All @@ -69,7 +69,7 @@ public void doFill(Object data) {

public void doFill(Object data, FillConfig fillConfig) {
if (excelWriter == null) {
throw new ExcelGenerateException("Must use 'EasyExcelFactory.write().sheet()' to call this method");
throw new ExcelGenerateException("Must use 'FastExcelFactory.write().sheet()' to call this method");
}
excelWriter.fill(data, fillConfig, build());
excelWriter.finish();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ public WriteTable build() {

public void doWrite(Collection<?> data) {
if (excelWriter == null) {
throw new ExcelGenerateException("Must use 'EasyExcelFactory.write().sheet().table()' to call this method");
throw new ExcelGenerateException("Must use 'FastExcelFactory.write().sheet().table()' to call this method");
}
excelWriter.write(data, writeSheet, build());
excelWriter.finish();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

import cn.idev.excel.EasyExcel;
import cn.idev.excel.util.BeanMapUtils;
import ai.chat2db.excel.support.cglib.beans.BeanMap;
import ai.chat2db.excel.support.cglib.core.DebuggingClassWriter;
import cn.idev.excel.support.cglib.beans.BeanMap;
import cn.idev.excel.support.cglib.core.DebuggingClassWriter;
import com.alibaba.fastjson2.JSON;

import org.junit.jupiter.api.Test;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
import cn.idev.excel.util.FileUtils;
import cn.idev.excel.util.ListUtils;
import cn.idev.excel.test.util.TestFileUtil;
import ai.chat2db.excel.support.cglib.beans.BeanMap;
import cn.idev.excel.support.cglib.beans.BeanMap;

import lombok.extern.slf4j.Slf4j;
import org.apache.poi.ss.usermodel.ClientAnchor;
Expand Down

0 comments on commit aa5fe56

Please sign in to comment.