Class ExcelEnumTypeTranslator
java.lang.Object
com.hybris.backoffice.excel.translators.AbstractValidationAwareTranslator<T>
com.hybris.backoffice.excel.translators.AbstractExcelValueTranslator<HybrisEnumValue>
com.hybris.backoffice.excel.translators.ExcelEnumTypeTranslator
- All Implemented Interfaces:
ExcelValueTranslator<HybrisEnumValue>,org.springframework.core.Ordered
Default excel translator for enum type.
-
Field Summary
Fields inherited from class com.hybris.backoffice.excel.translators.AbstractExcelValueTranslator
orderFields inherited from class com.hybris.backoffice.excel.translators.AbstractValidationAwareTranslator
validatorsFields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancanHandle(AttributeDescriptorModel attributeDescriptorModel) Indicates whether the translator can handle given attribute descriptor.exportData(HybrisEnumValue enumToExport) Converts given object to value which should be put into cell of exported excel file.importValue(AttributeDescriptorModel attributeDescriptor, ImportParameters importParameters) Imports single value instead of whole Impex object.voidsetExcelUniqueFilter(ExcelFilter<AttributeDescriptorModel> excelUniqueFilter) voidsetMandatoryFilter(ExcelFilter<AttributeDescriptorModel> mandatoryFilter) Methods inherited from class com.hybris.backoffice.excel.translators.AbstractExcelValueTranslator
getOrder, getTypeService, importData, isLocalizedOfType, setOrder, setTypeServiceMethods inherited from class com.hybris.backoffice.excel.translators.AbstractValidationAwareTranslator
getValidators, setValidators, validateMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.hybris.backoffice.excel.translators.ExcelValueTranslator
canHandle, exportData, referenceFormat
-
Constructor Details
-
ExcelEnumTypeTranslator
public ExcelEnumTypeTranslator()
-
-
Method Details
-
canHandle
Description copied from interface:ExcelValueTranslatorIndicates whether the translator can handle given attribute descriptor. This method is Recommended during importing excel file.- Parameters:
attributeDescriptorModel-AttributeDescriptorModel- Returns:
- whether the translator can handle request
-
exportData
Description copied from interface:ExcelValueTranslatorConverts given object to value which should be put into cell of exported excel file.- Returns:
- value which will be put into cell of exported excel file.
-
importValue
public ImpexValue importValue(AttributeDescriptorModel attributeDescriptor, ImportParameters importParameters) Description copied from class:AbstractExcelValueTranslatorImports single value instead of whole Impex object. Impex value consists of header and value.- Specified by:
importValuein classAbstractExcelValueTranslator<HybrisEnumValue>- Parameters:
attributeDescriptor-AttributeDescriptorModeldescribes attribute which should be importedimportParameters- - contains information about language for localized field, type code, parsed parameters inserted into excel's cell.- Returns:
ImpexValuevalue which should be imported
-
setExcelUniqueFilter
-
getMandatoryFilter
-
setMandatoryFilter
-