public class ExcelMetadataProcessor extends Object implements MetadataProcessor<FileConnection>
Modifier and Type | Field and Description |
---|---|
static String |
CELL_NUMBER |
static String |
FILE |
static String |
FIRST_DATA_ROW_NUMBER |
static String |
ROW_ID |
Constructor and Description |
---|
ExcelMetadataProcessor() |
Modifier and Type | Method and Description |
---|---|
int |
getDataRowNumber() |
String |
getExcelFileName() |
int |
getHeaderRowNumber() |
boolean |
getIgnoreEmptyHeaderCells() |
void |
process(MetadataFactory mf,
FileConnection conn) |
void |
setDataRowNumber(int dataRowNumber) |
void |
setExcelFileName(String fileName) |
void |
setHeaderRowNumber(int headerRowNumber) |
void |
setIgnoreEmptyHeaderCells(boolean ignoreEmpty) |
@ExtensionMetadataProperty(applicable=Table.class, datatype=java.lang.String.class, display="Excel File Name", description="Excel File name, use file name pattern if one than one file in the parent directory", required=true) public static final String FILE
@ExtensionMetadataProperty(applicable=Column.class, datatype=java.lang.Integer.class, display="Cell Number", description="Cell number, where the column information is defined. If column name is ROW_ID, define it as -1", required=true) public static final String CELL_NUMBER
@ExtensionMetadataProperty(applicable=Table.class, datatype=java.lang.Integer.class, display="First Data Number", description="First Row Number, where data rows start") public static final String FIRST_DATA_ROW_NUMBER
public static final String ROW_ID
public void process(MetadataFactory mf, FileConnection conn) throws TranslatorException
process
in interface MetadataProcessor<FileConnection>
TranslatorException
public void setExcelFileName(String fileName)
@TranslatorProperty(display="Header Row Number", category=IMPORT, description="Row number that contains the header information") public int getHeaderRowNumber()
public void setHeaderRowNumber(int headerRowNumber)
@TranslatorProperty(display="Ignore Empty Header Cells", category=IMPORT, description="When true any cells with empty value for header row are ignored, otherwise an empty header row cell indicates end of columns.") public boolean getIgnoreEmptyHeaderCells()
public void setIgnoreEmptyHeaderCells(boolean ignoreEmpty)
@TranslatorProperty(display="Data Row Number", category=IMPORT, description="Row number from which data rows start from") public int getDataRowNumber()
public void setDataRowNumber(int dataRowNumber)
@TranslatorProperty(display="Excel File", category=IMPORT, description="Name of the Excel file to read metadata from", required=true) public String getExcelFileName()
Copyright © 2017 JBoss by Red Hat. All rights reserved.