Interface WebMvcConfigurerAdapter

All Superinterfaces:
org.springframework.web.servlet.config.annotation.WebMvcConfigurer
All Known Implementing Classes:
CorsWebMvcConfigurer

public interface WebMvcConfigurerAdapter extends org.springframework.web.servlet.config.annotation.WebMvcConfigurer
为了兼容低版本的spring-webmvc,添加该适配器类
Author:
wangliang181230
  • Method Summary

    Modifier and Type
    Method
    Description
    default void
    addArgumentResolvers(List<org.springframework.web.method.support.HandlerMethodArgumentResolver> argumentResolvers)
     
    default void
    addCorsMappings(org.springframework.web.servlet.config.annotation.CorsRegistry registry)
     
    default void
    addFormatters(org.springframework.format.FormatterRegistry registry)
     
    default void
    addInterceptors(org.springframework.web.servlet.config.annotation.InterceptorRegistry registry)
     
    default void
    addResourceHandlers(org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry registry)
     
    default void
    addReturnValueHandlers(List<org.springframework.web.method.support.HandlerMethodReturnValueHandler> returnValueHandlers)
     
    default void
    addViewControllers(org.springframework.web.servlet.config.annotation.ViewControllerRegistry registry)
     
    default void
    configureAsyncSupport(org.springframework.web.servlet.config.annotation.AsyncSupportConfigurer configurer)
     
    default void
    configureContentNegotiation(org.springframework.web.servlet.config.annotation.ContentNegotiationConfigurer configurer)
     
    default void
    configureDefaultServletHandling(org.springframework.web.servlet.config.annotation.DefaultServletHandlerConfigurer configurer)
     
    default void
    configureHandlerExceptionResolvers(List<org.springframework.web.servlet.HandlerExceptionResolver> exceptionResolvers)
     
    default void
    configureMessageConverters(List<org.springframework.http.converter.HttpMessageConverter<?>> converters)
     
    default void
    configurePathMatch(org.springframework.web.servlet.config.annotation.PathMatchConfigurer configurer)
     
    default void
    configureViewResolvers(org.springframework.web.servlet.config.annotation.ViewResolverRegistry registry)
     
    default void
    extendHandlerExceptionResolvers(List<org.springframework.web.servlet.HandlerExceptionResolver> exceptionResolvers)
     
    default void
    extendMessageConverters(List<org.springframework.http.converter.HttpMessageConverter<?>> converters)
     
    default org.springframework.validation.MessageCodesResolver
     
    default org.springframework.validation.Validator
     
  • Method Details

    • configurePathMatch

      default void configurePathMatch(org.springframework.web.servlet.config.annotation.PathMatchConfigurer configurer)
      Specified by:
      configurePathMatch in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • configureContentNegotiation

      default void configureContentNegotiation(org.springframework.web.servlet.config.annotation.ContentNegotiationConfigurer configurer)
      Specified by:
      configureContentNegotiation in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • configureAsyncSupport

      default void configureAsyncSupport(org.springframework.web.servlet.config.annotation.AsyncSupportConfigurer configurer)
      Specified by:
      configureAsyncSupport in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • configureDefaultServletHandling

      default void configureDefaultServletHandling(org.springframework.web.servlet.config.annotation.DefaultServletHandlerConfigurer configurer)
      Specified by:
      configureDefaultServletHandling in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • addFormatters

      default void addFormatters(org.springframework.format.FormatterRegistry registry)
      Specified by:
      addFormatters in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • addInterceptors

      default void addInterceptors(org.springframework.web.servlet.config.annotation.InterceptorRegistry registry)
      Specified by:
      addInterceptors in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • addResourceHandlers

      default void addResourceHandlers(org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry registry)
      Specified by:
      addResourceHandlers in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • addCorsMappings

      default void addCorsMappings(org.springframework.web.servlet.config.annotation.CorsRegistry registry)
      Specified by:
      addCorsMappings in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • addViewControllers

      default void addViewControllers(org.springframework.web.servlet.config.annotation.ViewControllerRegistry registry)
      Specified by:
      addViewControllers in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • configureViewResolvers

      default void configureViewResolvers(org.springframework.web.servlet.config.annotation.ViewResolverRegistry registry)
      Specified by:
      configureViewResolvers in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • addArgumentResolvers

      default void addArgumentResolvers(List<org.springframework.web.method.support.HandlerMethodArgumentResolver> argumentResolvers)
      Specified by:
      addArgumentResolvers in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • addReturnValueHandlers

      default void addReturnValueHandlers(List<org.springframework.web.method.support.HandlerMethodReturnValueHandler> returnValueHandlers)
      Specified by:
      addReturnValueHandlers in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • configureMessageConverters

      default void configureMessageConverters(List<org.springframework.http.converter.HttpMessageConverter<?>> converters)
      Specified by:
      configureMessageConverters in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • extendMessageConverters

      default void extendMessageConverters(List<org.springframework.http.converter.HttpMessageConverter<?>> converters)
      Specified by:
      extendMessageConverters in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • configureHandlerExceptionResolvers

      default void configureHandlerExceptionResolvers(List<org.springframework.web.servlet.HandlerExceptionResolver> exceptionResolvers)
      Specified by:
      configureHandlerExceptionResolvers in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • extendHandlerExceptionResolvers

      default void extendHandlerExceptionResolvers(List<org.springframework.web.servlet.HandlerExceptionResolver> exceptionResolvers)
      Specified by:
      extendHandlerExceptionResolvers in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • getValidator

      default org.springframework.validation.Validator getValidator()
      Specified by:
      getValidator in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer
    • getMessageCodesResolver

      default org.springframework.validation.MessageCodesResolver getMessageCodesResolver()
      Specified by:
      getMessageCodesResolver in interface org.springframework.web.servlet.config.annotation.WebMvcConfigurer