diff --git a/org.springframework.web.servlet/src/main/java/org/springframework/web/servlet/config/AnnotationDrivenBeanDefinitionParser.java b/org.springframework.web.servlet/src/main/java/org/springframework/web/servlet/config/AnnotationDrivenBeanDefinitionParser.java index 405317c394a..6cd5ccd52a4 100644 --- a/org.springframework.web.servlet/src/main/java/org/springframework/web/servlet/config/AnnotationDrivenBeanDefinitionParser.java +++ b/org.springframework.web.servlet/src/main/java/org/springframework/web/servlet/config/AnnotationDrivenBeanDefinitionParser.java @@ -49,8 +49,8 @@ import org.springframework.web.servlet.handler.ConversionServiceExposingIntercep import org.springframework.web.servlet.handler.MappedInterceptor; import org.springframework.web.servlet.mvc.annotation.ResponseStatusExceptionResolver; import org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver; -import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMethodAdapter; -import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMethodMapping; +import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter; +import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping; import org.springframework.web.servlet.mvc.method.annotation.support.ServletWebArgumentResolverAdapter; import org.springframework.web.servlet.mvc.support.DefaultHandlerExceptionResolver; import org.w3c.dom.Element; @@ -105,7 +105,7 @@ class AnnotationDrivenBeanDefinitionParser implements BeanDefinitionParser { CompositeComponentDefinition compDefinition = new CompositeComponentDefinition(element.getTagName(), source); parserContext.pushContainingComponent(compDefinition); - RootBeanDefinition methodMappingDef = new RootBeanDefinition(RequestMappingHandlerMethodMapping.class); + RootBeanDefinition methodMappingDef = new RootBeanDefinition(RequestMappingHandlerMapping.class); methodMappingDef.setSource(source); methodMappingDef.setRole(BeanDefinition.ROLE_INFRASTRUCTURE); methodMappingDef.getPropertyValues().add("order", 0); @@ -125,7 +125,7 @@ class AnnotationDrivenBeanDefinitionParser implements BeanDefinitionParser { ManagedList> messageConverters = getMessageConverters(element, source, parserContext); ManagedList> argumentResolvers = getArgumentResolvers(element, source, parserContext); - RootBeanDefinition methodAdapterDef = new RootBeanDefinition(RequestMappingHandlerMethodAdapter.class); + RootBeanDefinition methodAdapterDef = new RootBeanDefinition(RequestMappingHandlerAdapter.class); methodAdapterDef.setSource(source); methodAdapterDef.setRole(BeanDefinition.ROLE_INFRASTRUCTURE); methodAdapterDef.getPropertyValues().add("webBindingInitializer", bindingDef); diff --git a/org.springframework.web.servlet/src/main/java/org/springframework/web/servlet/config/annotation/MvcConfiguration.java b/org.springframework.web.servlet/src/main/java/org/springframework/web/servlet/config/annotation/MvcConfiguration.java index 888ab7089d3..655cf7185ae 100644 --- a/org.springframework.web.servlet/src/main/java/org/springframework/web/servlet/config/annotation/MvcConfiguration.java +++ b/org.springframework.web.servlet/src/main/java/org/springframework/web/servlet/config/annotation/MvcConfiguration.java @@ -65,8 +65,8 @@ import org.springframework.web.servlet.mvc.HttpRequestHandlerAdapter; import org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter; import org.springframework.web.servlet.mvc.annotation.ResponseStatusExceptionResolver; import org.springframework.web.servlet.mvc.method.annotation.ExceptionHandlerExceptionResolver; -import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMethodAdapter; -import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMethodMapping; +import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter; +import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping; import org.springframework.web.servlet.mvc.support.DefaultHandlerExceptionResolver; /** @@ -79,7 +79,7 @@ import org.springframework.web.servlet.mvc.support.DefaultHandlerExceptionResolv * *
Registers these handler mappings: *
Registers these handler adapters: *
{@link ExceptionMethodMapping} is a key contributing class storing method-to-exception type mappings extracted * from {@link ExceptionHandler} annotations or from the list of method arguments on the exception-handling method. - * {@link ExceptionMethodMapping} assists with actually locating a method for a thrown exception. - * + * {@link ExceptionMethodMapping} assists with actually locating a method for a thrown exception. + * *
Once located the invocation of the exception-handling method is done using much of the same classes - * used for {@link RequestMapping} methods, which is described under {@link RequestMappingHandlerMethodAdapter}. - * - *
See {@link ExceptionHandler} for information on supported method arguments and return values for - * exception-handling methods. - * + * used for {@link RequestMapping} methods, which is described under {@link RequestMappingHandlerAdapter}. + * + *
See {@link ExceptionHandler} for information on supported method arguments and return values for
+ * exception-handling methods.
+ *
* @author Rossen Stoyanchev
* @since 3.1
*/
@@ -88,7 +88,7 @@ public class ExceptionHandlerExceptionResolver extends AbstractHandlerMethodExce
private List An existing {@link WebArgumentResolver} can either adapted with {@link ServletWebArgumentResolverAdapter}
- * or preferably converted to a {@link HandlerMethodArgumentResolver} instead.
+ * An existing {@link WebArgumentResolver} can either adapted with {@link ServletWebArgumentResolverAdapter}
+ * or preferably converted to a {@link HandlerMethodArgumentResolver} instead.
*/
public void setCustomArgumentResolvers(List Only {@link RequestMapping @RequestMapping}-annotated methods are considered.
- * Type-level {@link RequestMapping @RequestMapping} annotations are also detected and their
+ * Provides a {@link RequestMappingInfo} for the given method.
+ * Only {@link RequestMapping @RequestMapping}-annotated methods are considered.
+ * Type-level {@link RequestMapping @RequestMapping} annotations are also detected and their
* attributes combined with method-level {@link RequestMapping @RequestMapping} attributes.
*
* @param beanName the name of the bean the method belongs to
@@ -206,15 +206,15 @@ public class RequestMappingHandlerMethodMapping extends AbstractHandlerMethodMap
}
/**
- * A comparator for {@link RequestMappingInfo}s. Effective comparison can only be done in the context of a
- * specific request. For example not all {@link RequestMappingInfo} patterns may apply to the current request.
+ * A comparator for {@link RequestMappingInfo}s. Effective comparison can only be done in the context of a
+ * specific request. For example not all {@link RequestMappingInfo} patterns may apply to the current request.
* Therefore an HttpServletRequest is required as input.
*
- * Furthermore, the following assumptions are made about the input RequestMappings:
- * Furthermore, the following assumptions are made about the input RequestMappings:
+ *
*
- * @see RequestMappingHandlerMethodMapping#getMatchingMapping(RequestMappingInfo, String, HttpServletRequest)
+ * @see RequestMappingHandlerMapping#getMatchingMapping(RequestMappingInfo, String, HttpServletRequest)
*/
private class RequestMappingInfoComparator implements Comparator
- *
- *
+ *
* @author Rossen Stoyanchev
*/
@RunWith(Parameterized.class)
@@ -56,13 +56,13 @@ public class HandlerMethodMappingAnnotationDetectionTests {
@Parameters
public static Collection