Class AnonymousUserTranslator
java.lang.Object
de.hybris.platform.impex.jalo.translators.AbstractValueTranslator
de.hybris.platform.impex.jalo.translators.SingleValueTranslator
de.hybris.platform.ruleengineservices.impex.impl.AnonymousUserTranslator
Translator used for promotion rules that rely on 'anonymous' user within their definition.
Based on the
RuleEngineServicesConstants.CUSTOMER_CONDITION_USE_PK_PROPERTY
configuration flag performs conversion of 'anonymous' string value to the respective PK representation that matches
that of the anonymous user in the system.
INSERT_UPDATE PromotionSourceRule;code[unique=true];conditions[translator=de.hybris.platform.ruleengineservices.impex.impl.AnonymousUserTranslator]-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected ObjectconvertToJalo(String value, Item item) Converts a non-null and non-empty string into a jalo attribute value.protected StringconvertToString(Object object) Converts a non-null jalo attribute value into its string representation.protected UserServicevoidinit(StandardColumnDescriptor descriptor) Called once per header creation to allow configuring this translator using column modifiers etc.protected booleanisUsePk()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, isDebugEnabled, isInfoEnabled, setEmpty, setError, validate, warn, wasEmpty, wasUnresolved
-
Field Details
-
USER_SERVICE
- See Also:
-
-
Constructor Details
-
AnonymousUserTranslator
public AnonymousUserTranslator()
-
-
Method Details
-
init
Description copied from class:AbstractValueTranslatorCalled once per header creation to allow configuring this translator using column modifiers etc.- Overrides:
initin classAbstractValueTranslator- Parameters:
descriptor- descriptor where the value to translate belongs to
-
convertToJalo
Description copied from class:SingleValueTranslatorConverts a non-null and non-empty string into a jalo attribute value.- Specified by:
convertToJaloin classSingleValueTranslator- Parameters:
value- 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:
object- value to translate- Returns:
- translated value
-
isUsePk
protected boolean isUsePk() -
getUserService
-