Class DefaultMapToIntegrationKeyValueGenerator
- java.lang.Object
-
- de.hybris.platform.integrationservices.integrationkey.impl.AbstractIntegrationKeyValueGenerator<TypeDescriptor,java.util.Map<java.lang.String,java.lang.Object>>
-
- de.hybris.platform.integrationservices.integrationkey.impl.DefaultMapToIntegrationKeyValueGenerator
-
- All Implemented Interfaces:
IntegrationKeyValueGenerator<TypeDescriptor,java.util.Map<java.lang.String,java.lang.Object>>
public class DefaultMapToIntegrationKeyValueGenerator extends AbstractIntegrationKeyValueGenerator<TypeDescriptor,java.util.Map<java.lang.String,java.lang.Object>>
Generates integration key value for a givenTypeDescriptorfrom the attribute values represented by aMap<String, Object>, where the map key is the attribute name, and the map value is the corresponding attribute value.
-
-
Field Summary
Fields Modifier and Type Field Description protected static java.util.regex.Patternpattern
-
Constructor Summary
Constructors Constructor Description DefaultMapToIntegrationKeyValueGenerator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Stringgenerate(TypeDescriptor itemType, java.util.Map<java.lang.String,java.lang.Object> item)Generates a compound key value for a data structure that has one or several key attributes/properties.protected java.lang.StringtransformValueToString(java.lang.Object attributeValue)Implementations should transform a value into string representation.-
Methods inherited from class de.hybris.platform.integrationservices.integrationkey.impl.AbstractIntegrationKeyValueGenerator
encodeValue, getEncoding, setEncoding
-
-
-
-
Method Detail
-
generate
public java.lang.String generate(TypeDescriptor itemType, java.util.Map<java.lang.String,java.lang.Object> item)
Description copied from interface:IntegrationKeyValueGeneratorGenerates a compound key value for a data structure that has one or several key attributes/properties.- Parameters:
itemType- definition of the payload structure that can be used to determine which elements of the payload structure contain the key value(s).item- a data structure to generate the key value for.- Returns:
- integration key string representing the compound value of all key elements of the data structure
-
transformValueToString
protected java.lang.String transformValueToString(java.lang.Object attributeValue)
Description copied from class:AbstractIntegrationKeyValueGeneratorImplementations should transform a value into string representation. For instance Date.- Specified by:
transformValueToStringin classAbstractIntegrationKeyValueGenerator<TypeDescriptor,java.util.Map<java.lang.String,java.lang.Object>>- Parameters:
attributeValue- the value to be converted.- Returns:
- The string representation
-
-