public class EasyExcelFactory extends Object
构造器和说明 |
---|
EasyExcelFactory() |
限定符和类型 | 方法和说明 |
---|---|
static ExcelReader |
getReader(InputStream in,
AnalysisEventListener listener)
Get ExcelReader.
|
static ExcelWriter |
getWriter(OutputStream outputStream)
Get ExcelWriter
|
static ExcelWriter |
getWriter(OutputStream outputStream,
ExcelTypeEnum typeEnum,
boolean needHead)
Get ExcelWriter
|
static ExcelWriter |
getWriterWithTemp(InputStream temp,
OutputStream outputStream,
ExcelTypeEnum typeEnum,
boolean needHead)
Get ExcelWriter with a template file
|
static List<Object> |
read(InputStream in,
Sheet sheet)
Quickly read small files,no more than 10,000 lines.
|
static void |
readBySax(InputStream in,
Sheet sheet,
AnalysisEventListener listener)
Parsing large file
|
public static List<Object> read(InputStream in, Sheet sheet)
in
- the POI filesystem that contains the Workbook stream.sheet
- read sheet.public static void readBySax(InputStream in, Sheet sheet, AnalysisEventListener listener)
in
- the POI filesystem that contains the Workbook stream.sheet
- read sheet.listener
- Callback method after each row is parsed.public static ExcelReader getReader(InputStream in, AnalysisEventListener listener)
in
- the POI filesystem that contains the Workbook stream.listener
- Callback method after each row is parsed.public static ExcelWriter getWriter(OutputStream outputStream)
outputStream
- the java OutputStream you wish to write the data to.public static ExcelWriter getWriter(OutputStream outputStream, ExcelTypeEnum typeEnum, boolean needHead)
outputStream
- the java OutputStream you wish to write the data to.typeEnum
- 03 or 07needHead
- Do you need to write the header to the file?public static ExcelWriter getWriterWithTemp(InputStream temp, OutputStream outputStream, ExcelTypeEnum typeEnum, boolean needHead)
temp
- Append data after a POI file , Can be null(the template POI filesystem that contains the
Workbook stream)outputStream
- the java OutputStream you wish to write the data totypeEnum
- 03 or 07Copyright © 2018 Alibaba Group. All rights reserved.