Skip to content
This repository was archived by the owner on Sep 4, 2025. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions easyexcel-core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,6 @@
<groupId>org.apache.poi</groupId>
<artifactId>poi-ooxml</artifactId>
</dependency>
<dependency>
<groupId>org.apache.poi</groupId>
<artifactId>poi-ooxml-schemas</artifactId>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-csv</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
import com.alibaba.excel.util.StringUtils;

import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.poi.openxml4j.exceptions.InvalidFormatException;
import org.apache.poi.openxml4j.opc.OPCPackage;
import org.apache.poi.openxml4j.opc.PackageAccess;
Expand All @@ -41,10 +40,9 @@
import org.apache.poi.openxml4j.opc.PackagingURIHelper;
import org.apache.poi.ss.util.CellAddress;
import org.apache.poi.xssf.eventusermodel.XSSFReader;
import org.apache.poi.xssf.model.Comments;
import org.apache.poi.xssf.model.CommentsTable;
import org.apache.poi.xssf.model.SharedStringsTable;
import org.apache.poi.xssf.usermodel.XSSFComment;
import org.apache.poi.xssf.usermodel.XSSFRelation;
import org.openxmlformats.schemas.spreadsheetml.x2006.main.CTWorkbook;
import org.openxmlformats.schemas.spreadsheetml.x2006.main.CTWorkbookPr;
import org.openxmlformats.schemas.spreadsheetml.x2006.main.WorkbookDocument;
Expand Down Expand Up @@ -121,9 +119,9 @@ public XlsxSaxAnalyser(XlsxReadContext xlsxReadContext, InputStream decryptedStr
sheetList.add(new ReadSheet(index, ite.getSheetName()));
sheetMap.put(index, inputStream);
if (xlsxReadContext.readWorkbookHolder().getExtraReadSet().contains(CellExtraTypeEnum.COMMENT)) {
CommentsTable commentsTable = ite.getSheetComments();
if (null != commentsTable) {
commentsTableMap.put(index, commentsTable);
Comments comments = ite.getSheetComments();
if (comments instanceof CommentsTable) {
commentsTableMap.put(index, (CommentsTable) comments);
}
}
if (xlsxReadContext.readWorkbookHolder().getExtraReadSet().contains(CellExtraTypeEnum.HYPERLINK)) {
Expand Down Expand Up @@ -179,7 +177,7 @@ private void analysisUse1904WindowDate(XSSFReader xssfReader, XlsxReadWorkbookHo
}

private void analysisSharedStringsTable(InputStream sharedStringsTableInputStream,
XlsxReadWorkbookHolder xlsxReadWorkbookHolder) throws Exception {
XlsxReadWorkbookHolder xlsxReadWorkbookHolder) {
ContentHandler handler = new SharedStringsTableHandler(xlsxReadWorkbookHolder.getReadCache());
parseXmlSource(sharedStringsTableInputStream, handler);
xlsxReadWorkbookHolder.getReadCache().putFinished();
Expand All @@ -199,7 +197,7 @@ private OPCPackage readOpcPackage(XlsxReadWorkbookHolder xlsxReadWorkbookHolder,
}
File readTempFile = FileUtils.createCacheTmpFile();
xlsxReadWorkbookHolder.setTempFile(readTempFile);
File tempFile = new File(readTempFile.getPath(), UUID.randomUUID().toString() + ".xlsx");
File tempFile = new File(readTempFile.getPath(), UUID.randomUUID() + ".xlsx");
if (decryptedStream != null) {
FileUtils.writeToFile(tempFile, decryptedStream, false);
} else {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,11 +227,6 @@ public CellType getCachedFormulaResultType() {
return getCellType();
}

@Override
public CellType getCachedFormulaResultTypeEnum() {
return getCellType();
}

@Override
public String getCellFormula() {
if (formulaData == null) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ public void setFont(Font font) {
}

@Override
public short getFontIndex() {
public int getFontIndex() {
return 0;
}

Expand Down Expand Up @@ -125,11 +125,6 @@ public HorizontalAlignment getAlignment() {
return null;
}

@Override
public HorizontalAlignment getAlignmentEnum() {
return null;
}

@Override
public void setWrapText(boolean wrapped) {

Expand All @@ -150,11 +145,6 @@ public VerticalAlignment getVerticalAlignment() {
return null;
}

@Override
public VerticalAlignment getVerticalAlignmentEnum() {
return null;
}

@Override
public void setRotation(short rotation) {

Expand Down Expand Up @@ -185,11 +175,6 @@ public BorderStyle getBorderLeft() {
return null;
}

@Override
public BorderStyle getBorderLeftEnum() {
return null;
}

@Override
public void setBorderRight(BorderStyle border) {

Expand All @@ -200,11 +185,6 @@ public BorderStyle getBorderRight() {
return null;
}

@Override
public BorderStyle getBorderRightEnum() {
return null;
}

@Override
public void setBorderTop(BorderStyle border) {

Expand All @@ -215,11 +195,6 @@ public BorderStyle getBorderTop() {
return null;
}

@Override
public BorderStyle getBorderTopEnum() {
return null;
}

@Override
public void setBorderBottom(BorderStyle border) {

Expand All @@ -230,11 +205,6 @@ public BorderStyle getBorderBottom() {
return null;
}

@Override
public BorderStyle getBorderBottomEnum() {
return null;
}

@Override
public void setLeftBorderColor(short color) {

Expand Down Expand Up @@ -286,12 +256,12 @@ public FillPatternType getFillPattern() {
}

@Override
public FillPatternType getFillPatternEnum() {
return null;
public void setFillBackgroundColor(short bg) {

}

@Override
public void setFillBackgroundColor(short bg) {
public void setFillBackgroundColor(Color color) {

}

Expand All @@ -310,6 +280,11 @@ public void setFillForegroundColor(short bg) {

}

@Override
public void setFillForegroundColor(Color color) {

}

@Override
public short getFillForegroundColor() {
return 0;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,8 @@
import org.apache.poi.ss.usermodel.Footer;
import org.apache.poi.ss.usermodel.Header;
import org.apache.poi.ss.usermodel.Hyperlink;
import org.apache.poi.ss.usermodel.PageMargin;
import org.apache.poi.ss.usermodel.PaneType;
import org.apache.poi.ss.usermodel.PrintSetup;
import org.apache.poi.ss.usermodel.Row;
import org.apache.poi.ss.usermodel.Sheet;
Expand Down Expand Up @@ -397,11 +399,21 @@ public double getMargin(short margin) {
return 0;
}

@Override
public double getMargin(PageMargin pageMargin) {
return 0;
}

@Override
public void setMargin(short margin, double size) {

}

@Override
public void setMargin(PageMargin pageMargin, double v) {

}

@Override
public boolean getProtect() {
return false;
Expand Down Expand Up @@ -467,6 +479,11 @@ public void createSplitPane(int xSplitPos, int ySplitPos, int leftmostColumn, in

}

@Override
public void createSplitPane(int i, int i1, int i2, int i3, PaneType paneType) {

}

@Override
public PaneInformation getPaneInformation() {
return null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@
import lombok.Setter;
import org.apache.commons.compress.utils.Lists;
import org.apache.poi.ss.SpreadsheetVersion;
import org.apache.poi.ss.formula.EvaluationWorkbook;
import org.apache.poi.ss.formula.udf.UDFFinder;
import org.apache.poi.ss.usermodel.CellReferenceType;
import org.apache.poi.ss.usermodel.CellStyle;
import org.apache.poi.ss.usermodel.CreationHelper;
import org.apache.poi.ss.usermodel.DataFormat;
Expand Down Expand Up @@ -39,10 +41,9 @@ public class CsvWorkbook implements Workbook {

/**
* true if date uses 1904 windowing, or false if using 1900 date windowing.
*
* <p>
* default is false
*
* @return
*/
private Boolean use1904windowing;

Expand All @@ -53,7 +54,7 @@ public class CsvWorkbook implements Workbook {

/**
* Whether to use scientific Format.
*
* <p>
* default is false
*/
private Boolean useScientificFormat;
Expand Down Expand Up @@ -185,7 +186,7 @@ public Font findFont(boolean bold, short color, short fontHeight, String name, b
}

@Override
public short getNumberOfFonts() {
public int getNumberOfFonts() {
return 0;
}

Expand All @@ -194,11 +195,6 @@ public int getNumberOfFontsAsInt() {
return 0;
}

@Override
public Font getFontAt(short idx) {
return null;
}

@Override
public Font getFontAt(int idx) {
return null;
Expand Down Expand Up @@ -257,31 +253,11 @@ public List<? extends Name> getAllNames() {
return null;
}

@Override
public Name getNameAt(int nameIndex) {
return null;
}

@Override
public Name createName() {
return null;
}

@Override
public int getNameIndex(String name) {
return 0;
}

@Override
public void removeName(int index) {

}

@Override
public void removeName(String name) {

}

@Override
public void removeName(Name name) {

Expand Down Expand Up @@ -402,10 +378,25 @@ public SpreadsheetVersion getSpreadsheetVersion() {
}

@Override
public int addOlePackage(byte[] oleData, String label, String fileName, String command) throws IOException {
public int addOlePackage(byte[] oleData, String label, String fileName, String command) {
return 0;
}

@Override
public EvaluationWorkbook createEvaluationWorkbook() {
return null;
}

@Override
public CellReferenceType getCellReferenceType() {
return null;
}

@Override
public void setCellReferenceType(CellReferenceType cellReferenceType) {

}

@Override
public Iterator<Sheet> iterator() {
return null;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@

import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.poi.hssf.util.CellReference;
import org.apache.poi.ss.util.CellReference;
import org.apache.poi.ss.usermodel.DateUtil;
import org.apache.poi.ss.usermodel.FillPatternType;
import org.apache.poi.ss.usermodel.IndexedColors;
Expand Down
Loading