public class AbstractSpecialValueTranslator extends Object implements SpecialValueTranslator
SpecialValueTranslator with default method implementations. This allows extensions
to not specifying some methods if they are not needed.| Constructor and Description |
|---|
AbstractSpecialValueTranslator() |
| Modifier and Type | Method and Description |
|---|---|
void |
init(SpecialColumnDescriptor columnDescriptor)
Called once upon header creation to do some initial setup logic.
|
boolean |
isEmpty(String cellValue)
Treats
null and '' as empty cells. |
String |
performExport(Item item)
Called each time an item is exported using the enclosing header.
|
void |
performImport(String cellValue,
Item processedItem)
Called each time a non-empty cell value has to be imported.
|
void |
validate(String expr)
Validates the special column definition.
|
public void init(SpecialColumnDescriptor columnDescriptor) throws HeaderValidationException
SpecialValueTranslatorinit in interface SpecialValueTranslatorcolumnDescriptor - the newly created column descriptorHeaderValidationException - indicates that the column descriptor is not configured properlypublic void validate(String expr) throws HeaderValidationException
SpecialValueTranslatorvalidate in interface SpecialValueTranslatorexpr - the definition expressionHeaderValidationException - if the expression is not validpublic String performExport(Item item) throws ImpExException
SpecialValueTranslatorperformExport in interface SpecialValueTranslatoritem - the item to exportImpExException - indicates an export errorpublic void performImport(String cellValue, Item processedItem) throws ImpExException
SpecialValueTranslatorperformImport in interface SpecialValueTranslatorcellValue - the cell value stringprocessedItem - the item to import the value forImpExException - indicates an import errorpublic boolean isEmpty(String cellValue)
null and '' as empty cells.isEmpty in interface SpecialValueTranslatorcellValue - the cell value stringtrue if the cell value is emptySpecialValueTranslator.isEmpty(java.lang.String)Copyright © 2017 SAP SE. All Rights Reserved.