Class ClassificationAttributeValueTranslator
java.lang.Object
de.hybris.platform.impex.jalo.translators.AbstractValueTranslator
de.hybris.platform.impex.jalo.translators.SingleValueTranslator
de.hybris.platform.catalog.jalo.classification.impex.ClassificationAttributeValueTranslator
Translates a String to a
ClassificationAttributeValue and vice versa. For translating the String to an
attribute value, all assigned values of the specified classification attribute in respect to the classification class
will be checked for a matching of code or name. In case of translating an attribute value to a String simply the code
of the value is used.-
Constructor Summary
ConstructorsConstructorDescriptionCreates a new translator specifying the assignment which can be used for retrieving all assigned values as well as the calling translator for retrieving of context information. -
Method Summary
Modifier and TypeMethodDescriptionprotected ObjectconvertToJalo(String string, Item item) Converts a non-null and non-empty string into a jalo attribute value.protected StringconvertToString(Object obj) Converts a non-null jalo attribute value into its string representation.Methods inherited from class de.hybris.platform.impex.jalo.translators.SingleValueTranslator
exportValue, getEmptyValue, importValue, isEmptyMethods inherited from class de.hybris.platform.impex.jalo.translators.AbstractValueTranslator
clearStatus, createTranslator, createTranslator, createTranslator, debug, error, getColumnDescriptor, getFlexibleSearch, info, init, isDebugEnabled, isInfoEnabled, setEmpty, setError, validate, warn, wasEmpty, wasUnresolved
-
Constructor Details
-
ClassificationAttributeValueTranslator
Creates a new translator specifying the assignment which can be used for retrieving all assigned values as well as the calling translator for retrieving of context information.- Parameters:
assignment- will be used for retrieving all assigned values
-
-
Method Details
-
convertToJalo
Description copied from class:SingleValueTranslatorConverts a non-null and non-empty string into a jalo attribute value.- Specified by:
convertToJaloin classSingleValueTranslator- Parameters:
string- string to translateitem- item instance the translated value will be set to as attribute- Returns:
- Object translated value
-
convertToString
Description copied from class:SingleValueTranslatorConverts a non-null jalo attribute value into its string representation.- Specified by:
convertToStringin classSingleValueTranslator- Parameters:
obj- value to translate- Returns:
- translated value
-