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>>
-
-
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> entry)Generates a compound key value for a data structure that has one or several key attributes/properties.protected java.lang.ObjectgetProperty(java.util.Map<java.lang.String,java.lang.Object> entry, java.lang.String propertyName)Given an entry, it returns a property value.protected java.lang.StringgetTypeCode(TypeDescriptor type)Given a type, it returns its code representation.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
buildIntegrationKeyValueMatchingAliasOrder, encodeValue, entitySimpleKeys, getEncoding, serializeKeyToString, setEncoding
-
-
-
-
Method Detail
-
generate
public java.lang.String generate(TypeDescriptor itemType, java.util.Map<java.lang.String,java.lang.Object> entry)
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).entry- 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
-
getTypeCode
protected java.lang.String getTypeCode(TypeDescriptor type)
Description copied from class:AbstractIntegrationKeyValueGeneratorGiven a type, it returns its code representation.- Specified by:
getTypeCodein classAbstractIntegrationKeyValueGenerator<TypeDescriptor,java.util.Map<java.lang.String,java.lang.Object>>- Parameters:
type- The type to be used.- Returns:
- The type code.
-
getProperty
protected java.lang.Object getProperty(java.util.Map<java.lang.String,java.lang.Object> entry, java.lang.String propertyName)Description copied from class:AbstractIntegrationKeyValueGeneratorGiven an entry, it returns a property value.- Specified by:
getPropertyin classAbstractIntegrationKeyValueGenerator<TypeDescriptor,java.util.Map<java.lang.String,java.lang.Object>>- Parameters:
entry- The entry to be used.propertyName- The propertyName to look for.- Returns:
- The value related to propertyName.
-
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
-
-