Class RoutePredicateHandlerMapping

  • All Implemented Interfaces:
    org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanNameAware, org.springframework.context.ApplicationContextAware, org.springframework.core.Ordered, org.springframework.web.reactive.HandlerMapping

    public class RoutePredicateHandlerMapping
    extends org.springframework.web.reactive.handler.AbstractHandlerMapping
    Author:
    Spencer Gibb
    • Field Summary

      • Fields inherited from class org.springframework.web.reactive.handler.AbstractHandlerMapping

        mappingsLogger
      • Fields inherited from class org.springframework.context.support.ApplicationObjectSupport

        logger
      • Fields inherited from interface org.springframework.web.reactive.HandlerMapping

        BEST_MATCHING_HANDLER_ATTRIBUTE, BEST_MATCHING_PATTERN_ATTRIBUTE, MATRIX_VARIABLES_ATTRIBUTE, PATH_WITHIN_HANDLER_MAPPING_ATTRIBUTE, PRODUCIBLE_MEDIA_TYPES_ATTRIBUTE, URI_TEMPLATE_VARIABLES_ATTRIBUTE
      • Fields inherited from interface org.springframework.core.Ordered

        HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected org.springframework.web.cors.CorsConfiguration getCorsConfiguration​(Object handler, org.springframework.web.server.ServerWebExchange exchange)  
      protected reactor.core.publisher.Mono<?> getHandlerInternal​(org.springframework.web.server.ServerWebExchange exchange)  
      protected String getSimpleName()  
      protected reactor.core.publisher.Mono<Route> lookupRoute​(org.springframework.web.server.ServerWebExchange exchange)  
      protected void validateRoute​(Route route, org.springframework.web.server.ServerWebExchange exchange)
      Validate the given handler against the current request.
      • Methods inherited from class org.springframework.web.reactive.handler.AbstractHandlerMapping

        formatMappingName, getCorsProcessor, getHandler, getOrder, getPathPatternParser, hasCorsConfigurationSource, setBeanName, setCorsConfigurations, setCorsConfigurationSource, setCorsProcessor, setOrder, setUseCaseSensitiveMatch, setUseTrailingSlashMatch
      • Methods inherited from class org.springframework.context.support.ApplicationObjectSupport

        getApplicationContext, getMessageSourceAccessor, initApplicationContext, initApplicationContext, isContextRequired, obtainApplicationContext, requiredContextClass, setApplicationContext
    • Method Detail

      • getHandlerInternal

        protected reactor.core.publisher.Mono<?> getHandlerInternal​(org.springframework.web.server.ServerWebExchange exchange)
        Specified by:
        getHandlerInternal in class org.springframework.web.reactive.handler.AbstractHandlerMapping
      • getCorsConfiguration

        protected org.springframework.web.cors.CorsConfiguration getCorsConfiguration​(Object handler,
                                                                                      org.springframework.web.server.ServerWebExchange exchange)
        Overrides:
        getCorsConfiguration in class org.springframework.web.reactive.handler.AbstractHandlerMapping
      • lookupRoute

        protected reactor.core.publisher.Mono<Route> lookupRoute​(org.springframework.web.server.ServerWebExchange exchange)
      • validateRoute

        protected void validateRoute​(Route route,
                                     org.springframework.web.server.ServerWebExchange exchange)
        Validate the given handler against the current request.

        The default implementation is empty. Can be overridden in subclasses, for example to enforce specific preconditions expressed in URL mappings.

        Parameters:
        route - the Route object to validate
        exchange - current exchange
        Throws:
        Exception - if validation failed
      • getSimpleName

        protected String getSimpleName()