Class AbstractControllerUrlHandlerMapping
- 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.AbstractUrlHandlerMapping
- org.springframework.web.servlet.handler.AbstractDetectingUrlHandlerMapping
- org.springframework.web.servlet.mvc.support.AbstractControllerUrlHandlerMapping
 
 
 
 
 
 
- All Implemented Interfaces:
- Aware,- ApplicationContextAware,- Ordered,- ServletContextAware,- MatchableHandlerMapping,- HandlerMapping
 - Direct Known Subclasses:
- ControllerBeanNameHandlerMapping,- ControllerClassNameHandlerMapping
 - @Deprecated public abstract class AbstractControllerUrlHandlerMapping extends AbstractDetectingUrlHandlerMapping Deprecated.as of 4.3, in favor of annotation-driven handler methodsBase class for- HandlerMappingimplementations that derive URL paths according to conventions for specific controller types.- Since:
- 2.5.3
- Author:
- Juergen Hoeller
- See Also:
- ControllerClassNameHandlerMapping,- ControllerBeanNameHandlerMapping
 
- Field Summary- Fields inherited from class org.springframework.context.support.ApplicationObjectSupport- logger
 - Fields inherited from interface org.springframework.web.servlet.HandlerMapping- BEST_MATCHING_HANDLER_ATTRIBUTE, BEST_MATCHING_PATTERN_ATTRIBUTE, INTROSPECT_TYPE_LEVEL_MAPPING, 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
 
 - Constructor Summary- Constructors - Constructor - Description - AbstractControllerUrlHandlerMapping()Deprecated.
 - Method Summary- All Methods Instance Methods Abstract Methods Concrete Methods Deprecated Methods - Modifier and Type - Method - Description - protected abstract String[]- buildUrlsForHandler(String beanName, Class<?> beanClass)Deprecated.Abstract template method to be implemented by subclasses.- protected String[]- determineUrlsForHandler(String beanName)Deprecated.This implementation delegates to- buildUrlsForHandler(java.lang.String, java.lang.Class<?>), provided that- isEligibleForMapping(java.lang.String, java.lang.Class<?>)returns- true.- protected boolean- isControllerType(Class<?> beanClass)Deprecated.Determine whether the given bean class indicates a controller type that is supported by this mapping strategy.- protected boolean- isEligibleForMapping(String beanName, Class<?> beanClass)Deprecated.Determine whether the specified controller is excluded from this mapping.- protected boolean- isMultiActionControllerType(Class<?> beanClass)Deprecated.Determine whether the given bean class indicates a controller type that dispatches to multiple action methods.- void- setExcludedClasses(Class<?>... excludedClasses)Deprecated.Specify controller classes that should be excluded from this mapping.- void- setExcludedPackages(String... excludedPackages)Deprecated.Specify Java packages that should be excluded from this mapping.- void- setIncludeAnnotatedControllers(boolean includeAnnotatedControllers)Deprecated.Set whether to activate or deactivate detection of annotated controllers.- Methods inherited from class org.springframework.web.servlet.handler.AbstractDetectingUrlHandlerMapping- detectHandlers, initApplicationContext, setDetectHandlersInAncestorContexts
 - Methods inherited from class org.springframework.web.servlet.handler.AbstractUrlHandlerMapping- buildPathExposingHandler, exposePathWithinMapping, exposeUriTemplateVariables, getHandlerInternal, getHandlerMap, getRootHandler, lookupHandler, match, registerHandler, registerHandler, setLazyInitHandlers, setRootHandler, setUseTrailingSlashMatch, supportsTypeLevelMappings, useTrailingSlashMatch, validateHandler
 - Methods inherited from class org.springframework.web.servlet.handler.AbstractHandlerMapping- adaptInterceptor, detectMappedInterceptors, extendInterceptors, getAdaptedInterceptors, getCorsConfiguration, getCorsConfigurations, getCorsHandlerExecutionChain, getCorsProcessor, getDefaultHandler, getHandler, getHandlerExecutionChain, getMappedInterceptors, getOrder, getPathMatcher, getUrlPathHelper, initInterceptors, setAlwaysUseFullPath, setCorsConfigurations, setCorsProcessor, setDefaultHandler, setInterceptors, setOrder, setPathMatcher, setRemoveSemicolonContent, setUrlDecode, setUrlPathHelper
 - Methods inherited from class org.springframework.web.context.support.WebApplicationObjectSupport- getServletContext, getTempDir, getWebApplicationContext, initApplicationContext, initServletContext, isContextRequired, setServletContext
 - Methods inherited from class org.springframework.context.support.ApplicationObjectSupport- getApplicationContext, getMessageSourceAccessor, requiredContextClass, setApplicationContext
 - Methods inherited from class java.lang.Object- clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 - Methods inherited from interface org.springframework.web.servlet.HandlerMapping- getHandler
 
 
- Constructor Detail- AbstractControllerUrlHandlerMapping- public AbstractControllerUrlHandlerMapping() Deprecated.
 
 - Method Detail- setIncludeAnnotatedControllers- public void setIncludeAnnotatedControllers(boolean includeAnnotatedControllers) Deprecated.Set whether to activate or deactivate detection of annotated controllers.
 - setExcludedPackages- public void setExcludedPackages(String... excludedPackages) Deprecated.Specify Java packages that should be excluded from this mapping. Any classes in such a package (or any of its subpackages) will be ignored by this HandlerMapping.- Default is to exclude the entire "org.springframework.web.servlet.mvc" package, including its subpackages, since none of Spring's out-of-the-box Controller implementations is a reasonable candidate for this mapping strategy. Such controllers are typically handled by a separate HandlerMapping, e.g. a - BeanNameUrlHandlerMapping, alongside this ControllerClassNameHandlerMapping for application controllers.
 - setExcludedClasses- public void setExcludedClasses(Class<?>... excludedClasses) Deprecated.Specify controller classes that should be excluded from this mapping. Any such classes will simply be ignored by this HandlerMapping.
 - determineUrlsForHandler- protected String[] determineUrlsForHandler(String beanName) Deprecated.This implementation delegates to- buildUrlsForHandler(java.lang.String, java.lang.Class<?>), provided that- isEligibleForMapping(java.lang.String, java.lang.Class<?>)returns- true.- Specified by:
- determineUrlsForHandlerin class- AbstractDetectingUrlHandlerMapping
- Parameters:
- beanName- the name of the candidate bean
- Returns:
- the URLs determined for the bean, or nullor an empty array if none
 
 - isEligibleForMapping- protected boolean isEligibleForMapping(String beanName, Class<?> beanClass) Deprecated.Determine whether the specified controller is excluded from this mapping.- Parameters:
- beanName- the name of the controller bean
- beanClass- the concrete class of the controller bean
- Returns:
- whether the specified class is excluded
- See Also:
- setExcludedPackages(java.lang.String...),- setExcludedClasses(java.lang.Class<?>...)
 
 - isControllerType- protected boolean isControllerType(Class<?> beanClass) Deprecated.Determine whether the given bean class indicates a controller type that is supported by this mapping strategy.- Parameters:
- beanClass- the class to introspect
 
 - isMultiActionControllerType- protected boolean isMultiActionControllerType(Class<?> beanClass) Deprecated.Determine whether the given bean class indicates a controller type that dispatches to multiple action methods.- Parameters:
- beanClass- the class to introspect
 
 - buildUrlsForHandler- protected abstract String[] buildUrlsForHandler(String beanName, Class<?> beanClass) Deprecated.Abstract template method to be implemented by subclasses.- Parameters:
- beanName- the name of the bean
- beanClass- the type of the bean
- Returns:
- the URLs determined for the bean