Class AbstractMapConverter<K,V>
java.lang.Object
com.broadleafcommerce.common.jpa.converter.AbstractMapConverter<K,V>
- Type Parameters:
K
- The type of the map key to be transformedV
- The type of the map value to be transformed
- Direct Known Subclasses:
InstantMapConverter
,ObjectMapConverter
,StringMapConverter
public abstract class AbstractMapConverter<K,V>
extends Object
implements javax.persistence.AttributeConverter<Map<K,V>,String>
Transforms a map of
AbstractMapConverter
, AbstractMapConverter
into a JSON object String
and vice-versa.-
Constructor Summary
ConstructorDescriptionAbstractMapConverter
(Class<?> keyType, Class<?> valueType, com.fasterxml.jackson.databind.ObjectMapper objectMapper) AbstractMapConverter
(Class<?> keyType, Class<?> valueType, com.fasterxml.jackson.databind.ObjectMapper objectMapper, boolean initIfNull) -
Method Summary
Modifier and TypeMethodDescriptionconvertToDatabaseColumn
(Map<K, V> attribute) convertToEntityAttribute
(String dbData) com.fasterxml.jackson.databind.ObjectMapper
-
Constructor Details
-
AbstractMapConverter
-
AbstractMapConverter
-
-
Method Details
-
convertToDatabaseColumn
-
convertToEntityAttribute
-
getObjectMapper
public com.fasterxml.jackson.databind.ObjectMapper getObjectMapper()
-