public final class ExcelFactory extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
static <R> ExcelBindReader<R> |
createReader(File file,
Class<R> excelClass,
String... ignores)
Create an Excel reader
|
static <R> ExcelBindReader<R> |
createReader(InputStream inputStream,
Class<R> excelClass,
String... ignores)
Create an Excel reader
|
static <R> ExcelBindReader<R> |
createReader(org.springframework.web.multipart.MultipartFile file,
Class<R> excelClass,
String... ignores)
Create an Excel reader
|
static ExcelSimpleWriter |
createSimpleWriter(String fileName,
javax.servlet.http.HttpServletResponse response,
boolean initDefaultStyle)
Create an excel writer
|
static ExcelSimpleWriter |
createSimpleWriter(String fileName,
javax.servlet.http.HttpServletResponse response,
ExcelType excelType)
Create an excel writer
|
static ExcelSimpleWriter |
createSimpleWriter(String fileName,
javax.servlet.http.HttpServletResponse response,
ExcelType excelType,
int windowSize)
Create an excel writer
|
static ExcelSimpleWriter |
createSimpleWriter(String fileName,
javax.servlet.http.HttpServletResponse response,
ExcelType excelType,
int windowSize,
boolean initDefaultStyle)
Create an excel writer
|
static ExcelBindWriter |
createWriter(Class<?> excelClass,
javax.servlet.http.HttpServletResponse response,
boolean initDefaultStyle,
String... ignores)
Create an excel writer
|
static ExcelBindWriter |
createWriter(Class<?> excelClass,
javax.servlet.http.HttpServletResponse response,
String... ignores)
Create an excel writer
|
static ExcelBindWriter |
createWriter(String fileName,
Class<?> excelClass,
javax.servlet.http.HttpServletResponse response,
boolean initDefaultStyle,
String... ignores)
Create an excel writer
|
static ExcelBindWriter |
createWriter(String fileName,
Class<?> excelClass,
javax.servlet.http.HttpServletResponse response,
String... ignores)
Create an excel writer
|
public static ExcelBindWriter createWriter(Class<?> excelClass, javax.servlet.http.HttpServletResponse response, String... ignores)
excelClass - Excel mapped entityresponse - responseignores - Which table heads to be ignored when exporting, in the case of multiple table heads,
there are more than one child table heads under the ignored table head,
then the child table head will be ignored, if the ignored table head is from the table head
then it is ignoredpublic static ExcelBindWriter createWriter(Class<?> excelClass, javax.servlet.http.HttpServletResponse response, boolean initDefaultStyle, String... ignores)
excelClass - Excel mapped entityresponse - responseignores - The name of the header to be ignored when exporting.
If it is a parent, all children below it will be ignored as wellinitDefaultStyle - Whether init default excel stylepublic static ExcelBindWriter createWriter(String fileName, Class<?> excelClass, javax.servlet.http.HttpServletResponse response, String... ignores)
excelClass - Excel mapped entityresponse - responseignores - The name of the header to be ignored when exporting.
If it is a parent, all children below it will be ignored as wellfileName - Excel file name,The priority is higher than the annotation specificationpublic static ExcelBindWriter createWriter(String fileName, Class<?> excelClass, javax.servlet.http.HttpServletResponse response, boolean initDefaultStyle, String... ignores)
fileName - Excel file name,The priority is higher than the annotation specificationexcelClass - Excel mapped entityresponse - responseignores - The name of the header to be ignored when exporting.
If it is a parent, all children below it will be ignored as wellinitDefaultStyle - Whether init default excel stylepublic static ExcelSimpleWriter createSimpleWriter(String fileName, javax.servlet.http.HttpServletResponse response, boolean initDefaultStyle)
fileName - Excel file nameresponse - responseinitDefaultStyle - Whether init default excel stylepublic static ExcelSimpleWriter createSimpleWriter(String fileName, javax.servlet.http.HttpServletResponse response, ExcelType excelType)
fileName - Excel file nameresponse - responseexcelType - Excel file typepublic static ExcelSimpleWriter createSimpleWriter(String fileName, javax.servlet.http.HttpServletResponse response, ExcelType excelType, int windowSize)
fileName - Excel file nameresponse - responseexcelType - Excel file typewindowSize - Window size, which is flushed to disk when exported
if the data that has been written out exceeds the specified size
only for xlsxpublic static ExcelSimpleWriter createSimpleWriter(String fileName, javax.servlet.http.HttpServletResponse response, ExcelType excelType, int windowSize, boolean initDefaultStyle)
fileName - Excel file nameresponse - responseexcelType - Excel file typewindowSize - Window size, which is flushed to disk when exported
if the data that has been written out exceeds the specified size
only for xlsxinitDefaultStyle - Whether init default excel stylepublic static <R> ExcelBindReader<R> createReader(org.springframework.web.multipart.MultipartFile file, Class<R> excelClass, String... ignores)
R - Entity typefile - Excel fileexcelClass - Excel mapped entityignores - The name of the header to be ignored during import.
If it is the parent header, all children below it will be ignoredpublic static <R> ExcelBindReader<R> createReader(File file, Class<R> excelClass, String... ignores)
R - Entity typefile - Excel fileexcelClass - Excel mapped entityignores - The name of the header to be ignored during import.
If it is the parent header, all children below it will be ignoredpublic static <R> ExcelBindReader<R> createReader(InputStream inputStream, Class<R> excelClass, String... ignores)
R - Entity typeinputStream - Excel file inputStreamexcelClass - Excel mapped entityignores - Ignore the array of actual Excel table headers that you read when importingCopyright © 2021. All rights reserved.