Class JacksonYamlHttpMessageConverter
java.lang.Object
org.springframework.http.converter.AbstractHttpMessageConverter<Object>
org.springframework.http.converter.AbstractSmartHttpMessageConverter<Object>
org.springframework.http.converter.AbstractJacksonHttpMessageConverter
org.springframework.http.converter.yaml.JacksonYamlHttpMessageConverter
- All Implemented Interfaces:
HttpMessageConverter<Object>,SmartHttpMessageConverter<Object>
Implementation of
HttpMessageConverter that can read and write the YAML
data format using
the dedicated Jackson 3.x extension.
By default, this converter supports the MediaType.APPLICATION_YAML_VALUE
media type. This can be overridden by setting the supportedMediaTypes property.
The default constructor loads JacksonModules
found by MapperBuilder.findModules(ClassLoader).
- Since:
- 7.0
- Author:
- Sebastien Deleuze
-
Field Summary
Fields inherited from class org.springframework.http.converter.AbstractJacksonHttpMessageConverter
defaultObjectMapperFields inherited from class org.springframework.http.converter.AbstractHttpMessageConverter
logger -
Constructor Summary
ConstructorsConstructorDescriptionConstruct a new instance with aYAMLMappercustomized with theJacksonModules found byMapperBuilder.findModules(ClassLoader).JacksonYamlHttpMessageConverter(tools.jackson.dataformat.yaml.YAMLMapper mapper) Construct a new instance with the providedYAMLMapper. -
Method Summary
Methods inherited from class org.springframework.http.converter.AbstractJacksonHttpMessageConverter
canRead, canWrite, customizeReader, customizeWriter, getCharset, getJavaType, getJsonEncoding, getMediaTypesForProblemDetail, getObjectMapper, getObjectMappersForType, getSupportedMediaTypes, read, readInternal, registerObjectMappersForType, setSupportedMediaTypes, supportsRepeatableWrites, writeInternal, writePrefix, writeSuffixMethods inherited from class org.springframework.http.converter.AbstractSmartHttpMessageConverter
canWrite, supports, write, writeInternalMethods inherited from class org.springframework.http.converter.AbstractHttpMessageConverter
addDefaultHeaders, canRead, canRead, canWrite, getContentLength, getDefaultCharset, getDefaultContentType, getSupportedMediaTypes, read, setDefaultCharset, writeMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.springframework.http.converter.HttpMessageConverter
getSupportedMediaTypesMethods inherited from interface org.springframework.http.converter.SmartHttpMessageConverter
canRead, read, write
-
Constructor Details
-
JacksonYamlHttpMessageConverter
public JacksonYamlHttpMessageConverter()Construct a new instance with aYAMLMappercustomized with theJacksonModules found byMapperBuilder.findModules(ClassLoader). -
JacksonYamlHttpMessageConverter
public JacksonYamlHttpMessageConverter(tools.jackson.dataformat.yaml.YAMLMapper mapper) Construct a new instance with the providedYAMLMapper.- See Also:
-