Package org.aoju.bus.goalie.handler
Class ApiRequestMappingHandlerMapping
java.lang.Object
org.springframework.context.support.ApplicationObjectSupport
org.springframework.web.context.support.WebApplicationObjectSupport
org.springframework.web.servlet.handler.AbstractHandlerMapping
org.springframework.web.servlet.handler.AbstractHandlerMethodMapping<org.springframework.web.servlet.mvc.method.RequestMappingInfo>
org.springframework.web.servlet.mvc.method.RequestMappingInfoHandlerMapping
org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping
org.aoju.bus.goalie.handler.ApiRequestMappingHandlerMapping
- All Implemented Interfaces:
org.springframework.beans.factory.Aware,org.springframework.beans.factory.BeanNameAware,org.springframework.beans.factory.InitializingBean,org.springframework.context.ApplicationContextAware,org.springframework.context.EmbeddedValueResolverAware,org.springframework.core.Ordered,org.springframework.web.context.ServletContextAware,org.springframework.web.servlet.handler.MatchableHandlerMapping,org.springframework.web.servlet.HandlerMapping
public class ApiRequestMappingHandlerMapping
extends org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping
- Since:
- Java 17++
- Author:
- Kimi Liu
-
Field Summary
Fields inherited from class org.springframework.web.servlet.handler.AbstractHandlerMapping
mappingsLoggerFields inherited from class org.springframework.context.support.ApplicationObjectSupport
loggerFields inherited from interface org.springframework.web.servlet.HandlerMapping
BEST_MATCHING_HANDLER_ATTRIBUTE, BEST_MATCHING_PATTERN_ATTRIBUTE, INTROSPECT_TYPE_LEVEL_MAPPING, LOOKUP_PATH, MATRIX_VARIABLES_ATTRIBUTE, PATH_WITHIN_HANDLER_MAPPING_ATTRIBUTE, PRODUCIBLE_MEDIA_TYPES_ATTRIBUTE, URI_TEMPLATE_VARIABLES_ATTRIBUTEFields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected org.springframework.web.servlet.mvc.condition.RequestCondition<?>getCustomMethodCondition(Method method) 重新定义clientversion的条件匹配protected org.springframework.web.servlet.mvc.condition.RequestCondition<?>getCustomTypeCondition(Class<?> handlerType) protected org.springframework.web.servlet.mvc.method.RequestMappingInfogetMappingForMethod(Method method, Class<?> handlerType) 重写此处,保证读取我们的注解apiversionMethods inherited from class org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping
afterPropertiesSet, createRequestMappingInfo, getBuilderConfiguration, getContentNegotiationManager, getFileExtensions, getPathPrefixes, initCorsConfiguration, isHandler, match, registerHandlerMethod, registerMapping, resolveEmbeddedValuesInPatterns, setContentNegotiationManager, setEmbeddedValueResolver, setPathPrefixes, setUseRegisteredSuffixPatternMatch, setUseSuffixPatternMatch, setUseTrailingSlashMatch, useRegisteredSuffixPatternMatch, useSuffixPatternMatch, useTrailingSlashMatchMethods inherited from class org.springframework.web.servlet.mvc.method.RequestMappingInfoHandlerMapping
getDirectPaths, getHandlerInternal, getMappingComparator, getMappingPathPatterns, getMatchingMapping, handleMatch, handleNoMatchMethods inherited from class org.springframework.web.servlet.handler.AbstractHandlerMethodMapping
createHandlerMethod, detectHandlerMethods, getCandidateBeanNames, getCorsConfiguration, getHandlerMethods, getHandlerMethodsForMappingName, getNamingStrategy, handlerMethodsInitialized, hasCorsConfigurationSource, initHandlerMethods, lookupHandlerMethod, processCandidateBean, setDetectHandlerMethodsInAncestorContexts, setHandlerMethodMappingNamingStrategy, setPatternParser, unregisterMappingMethods inherited from class org.springframework.web.servlet.handler.AbstractHandlerMapping
adaptInterceptor, detectMappedInterceptors, extendInterceptors, formatMappingName, getAdaptedInterceptors, getCorsConfigurationSource, getCorsHandlerExecutionChain, getCorsProcessor, getDefaultHandler, getHandler, getHandlerExecutionChain, getMappedInterceptors, getOrder, getPathMatcher, getPatternParser, getUrlPathHelper, initApplicationContext, initInterceptors, initLookupPath, setAlwaysUseFullPath, setBeanName, setCorsConfigurations, setCorsConfigurationSource, setCorsProcessor, setDefaultHandler, setInterceptors, setOrder, setPathMatcher, setRemoveSemicolonContent, setUrlDecode, setUrlPathHelper, usesPathPatternsMethods inherited from class org.springframework.web.context.support.WebApplicationObjectSupport
getServletContext, getTempDir, getWebApplicationContext, initApplicationContext, initServletContext, isContextRequired, setServletContextMethods inherited from class org.springframework.context.support.ApplicationObjectSupport
getApplicationContext, getMessageSourceAccessor, obtainApplicationContext, requiredContextClass, setApplicationContextMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.springframework.web.servlet.HandlerMapping
getHandler, usesPathPatternsMethods inherited from interface org.springframework.web.servlet.handler.MatchableHandlerMapping
getPatternParser
-
Constructor Details
-
ApiRequestMappingHandlerMapping
public ApiRequestMappingHandlerMapping()
-
-
Method Details
-
getMappingForMethod
protected org.springframework.web.servlet.mvc.method.RequestMappingInfo getMappingForMethod(Method method, Class<?> handlerType) 重写此处,保证读取我们的注解apiversion- Overrides:
getMappingForMethodin classorg.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping- Parameters:
method- 请求方法handlerType- 拦截器- Returns:
- 处理结果
-
getCustomTypeCondition
protected org.springframework.web.servlet.mvc.condition.RequestCondition<?> getCustomTypeCondition(Class<?> handlerType) - Overrides:
getCustomTypeConditionin classorg.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping
-
getCustomMethodCondition
protected org.springframework.web.servlet.mvc.condition.RequestCondition<?> getCustomMethodCondition(Method method) 重新定义clientversion的条件匹配- Overrides:
getCustomMethodConditionin classorg.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping- Parameters:
method- 请求方法- Returns:
- 匹配规则
-