Class HalMediaTypeConfiguration
java.lang.Object
org.springframework.hateoas.mediatype.hal.HalMediaTypeConfiguration
- All Implemented Interfaces:
HypermediaMappingInformation
@Configuration(proxyBeanMethods=false)
public class HalMediaTypeConfiguration
extends Object
implements HypermediaMappingInformation
Spring configuration to set up HAL support.
- Author:
- Greg Turnquist, Oliver Drotbohm
-
Constructor Summary
ConstructorsConstructorDescriptionHalMediaTypeConfiguration
(LinkRelationProvider relProvider, ObjectProvider<CurieProvider> curieProvider, ObjectProvider<HalConfiguration> halConfiguration, ObjectProvider<MediaTypeConfigurationCustomizer<HalConfiguration>> customizers, MessageResolver resolver, AutowireCapableBeanFactory beanFactory) -
Method Summary
Modifier and TypeMethodDescriptioncom.fasterxml.jackson.databind.ObjectMapper
configureObjectMapper
(com.fasterxml.jackson.databind.ObjectMapper mapper) Configure anObjectMapper
and register custom serializers and deserializers for the supported media types.AllMediaType
s this hypermedia can handle.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.springframework.hateoas.config.HypermediaMappingInformation
getJacksonModule, getRootType
-
Constructor Details
-
HalMediaTypeConfiguration
public HalMediaTypeConfiguration(LinkRelationProvider relProvider, ObjectProvider<CurieProvider> curieProvider, ObjectProvider<HalConfiguration> halConfiguration, ObjectProvider<MediaTypeConfigurationCustomizer<HalConfiguration>> customizers, MessageResolver resolver, AutowireCapableBeanFactory beanFactory)
-
-
Method Details
-
getMediaTypes
Description copied from interface:HypermediaMappingInformation
AllMediaType
s this hypermedia can handle.- Specified by:
getMediaTypes
in interfaceHypermediaMappingInformation
- Returns:
-
configureObjectMapper
public com.fasterxml.jackson.databind.ObjectMapper configureObjectMapper(com.fasterxml.jackson.databind.ObjectMapper mapper) Description copied from interface:HypermediaMappingInformation
Configure anObjectMapper
and register custom serializers and deserializers for the supported media types. If all you want to do is register a JacksonModule
, prefer implementingHypermediaMappingInformation.getJacksonModule()
.- Specified by:
configureObjectMapper
in interfaceHypermediaMappingInformation
- Returns:
- See Also:
-