public class ConfigurableTypeInformationMapper extends Object implements TypeInformationMapper
TypeInformationMapper implementation that can be either set up using a MappingContext or manually set
up Map of String aliases to types. If a MappingContext is used the Map will be build
inspecting the PersistentEntity instances for type alias information.| Constructor and Description |
|---|
ConfigurableTypeInformationMapper(Map<? extends Class<?>,String> sourceTypeMap)
Creates a new
ConfigurableTypeMapper for the given type map. |
ConfigurableTypeInformationMapper(MappingContext<? extends PersistentEntity<?,?>,?> mappingContext)
Creates a
ConfigurableTypeInformationMapper from the given MappingContext. |
| Modifier and Type | Method and Description |
|---|---|
Object |
createAliasFor(TypeInformation<?> type)
Returns the alias to be used for the given
TypeInformation. |
TypeInformation<?> |
resolveTypeFrom(Object alias)
Returns the actual
TypeInformation to be used for the given alias. |
public ConfigurableTypeInformationMapper(MappingContext<? extends PersistentEntity<?,?>,?> mappingContext)
ConfigurableTypeInformationMapper from the given MappingContext. Inspects all
PersistentEntity instances for alias information and builds a Map of aliases to types from it.mappingContext - public Object createAliasFor(TypeInformation<?> type)
TypeInformationMapperTypeInformation.createAliasFor in interface TypeInformationMapperpublic TypeInformation<?> resolveTypeFrom(Object alias)
TypeInformationMapperTypeInformation to be used for the given alias.resolveTypeFrom in interface TypeInformationMapperCopyright © 2012. All Rights Reserved.