@Configuration
@EnableWebMvc
public class JsonConfig
extends java.lang.Object
implements org.springframework.web.servlet.config.annotation.WebMvcConfigurer
| 构造器和说明 |
|---|
JsonConfig() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
configureMessageConverters(java.util.List<org.springframework.http.converter.HttpMessageConverter<?>> converters) |
com.alibaba.fastjson.support.spring.FastJsonHttpMessageConverter |
getFastJsonHttpMessageConverters() |
org.springframework.http.converter.json.MappingJackson2HttpMessageConverter |
getMappingJackson2HttpMessageConverter() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitaddArgumentResolvers, addCorsMappings, addFormatters, addInterceptors, addResourceHandlers, addReturnValueHandlers, addViewControllers, configureAsyncSupport, configureContentNegotiation, configureDefaultServletHandling, configureHandlerExceptionResolvers, configurePathMatch, configureViewResolvers, extendHandlerExceptionResolvers, extendMessageConverters, getMessageCodesResolver, getValidatorpublic void configureMessageConverters(java.util.List<org.springframework.http.converter.HttpMessageConverter<?>> converters)
configureMessageConverters 在接口中 org.springframework.web.servlet.config.annotation.WebMvcConfigurer@Bean public org.springframework.http.converter.json.MappingJackson2HttpMessageConverter getMappingJackson2HttpMessageConverter()
@Bean public com.alibaba.fastjson.support.spring.FastJsonHttpMessageConverter getFastJsonHttpMessageConverters()