public class Parser extends Object
| Constructor and Description |
|---|
Parser(ExcelFactoryType excelFactoryType,
File file)
Initialize the Parser, will create the headers map using the first row.
|
| Modifier and Type | Method and Description |
|---|---|
protected Date |
dateParser(String value)
Parses the date columns in dd-MM-YYYY format.
|
protected String |
getCellValue(org.apache.poi.ss.usermodel.Cell cell)
Returns the text value of a column.
If it's a date or number, it will be converted to string and then returned. |
protected ExcelFactoryType |
getExcelFactoryType() |
protected Map<String,String> |
getHeadersMap() |
protected org.apache.poi.ss.usermodel.Workbook |
getWorkbook() |
protected boolean |
isEmptyRow(org.apache.poi.ss.usermodel.Row row)
Checks whether an encountered row is empty or not.
|
public Parser(ExcelFactoryType excelFactoryType, File file) throws Exception
excelFactoryType - the factory type for the parser.file - the file being parsed.Exception - any handling exceptionprotected String getCellValue(org.apache.poi.ss.usermodel.Cell cell)
cell - the apache poi cell for excel cellprotected Date dateParser(String value)
value - the date value in normal stringprotected boolean isEmptyRow(org.apache.poi.ss.usermodel.Row row)
row - excel rowprotected org.apache.poi.ss.usermodel.Workbook getWorkbook()
protected ExcelFactoryType getExcelFactoryType()
Copyright © 2019 Gizbel Technologies Private Limited. All rights reserved.