Generated by
JDiff

org.springframework.web.servlet.mvc.method.annotation Documentation Differences

This file contains all the changes in documentation in the package org.springframework.web.servlet.mvc.method.annotation as colored differences. Deletions are shown like this, and additions are shown like this.
If no deletions or additions are shown in an entry, the HTML tags will be what has changed. The new HTML tags are shown in the differences. If no documentation existed, and then some was added in a later version, this change is noted in the appropriate class pages of differences, but the change is not shown on this page. Only changes in existing text are shown here. Similarly, documentation which was inherited from another class or interface is not shown here.
Note that an HTML error in the new documentation may cause the display of other documentation changes to be presented incorrectly. For instance, failure to close a <code> tag will cause all subsequent paragraphs to be displayed differently.

Class AbstractMessageConverterMethodArgumentResolver

A base class for resolving method argument values by reading from the body ofof a request with HttpMessageConverters. @author Arjen Poutsma @author Rossen Stoyanchev @since 3.1

Class ExceptionHandlerExceptionResolver

An AbstractHandlerMethodExceptionResolver that resolves exceptions through {@code @ExceptionHandler} methods.

Support for custom argument and return value types can be added via .setCustomArgumentResolvers and .setCustomReturnValueHandlers. Or alternatively to re-configure all argument and return value types use .setArgumentResolvers and .setReturnValueHandlers(List). @author Rossen Stoyanchev @since 3.1

Class ExceptionHandlerExceptionResolver, ModelAndView doResolveHandlerMethodException(HttpServletRequest, HttpServletResponse, HandlerMethod, Exception)

Find an {@code @ExceptionHandler} method and invoke it to handle the raised exception.
Class ExceptionHandlerExceptionResolver, HandlerMethodArgumentResolverComposite getArgumentResolvers()

Return the configured argument resolvers, or possibly {@code null} ifif not initialized yet via .afterPropertiesSet().
Class ExceptionHandlerExceptionResolver, List<HandlerMethodReturnValueHandler> getDefaultReturnValueHandlers()

Return the list of return value handlers to use including built-in andand custom handlers provided via .setReturnValueHandlers.
Class ExceptionHandlerExceptionResolver, ServletInvocableHandlerMethod getExceptionHandlerMethod(HandlerMethod, Exception)

Find thean {@code @ExceptionHandler} method for the given exception. The defaultdefault implementation searches @ExceptionHandler methods in the class hierarchy of the method that raised thecontroller first and if exceptionnot found, it continues searching for additional {@code @ExceptionHandler} methods assuming some ControllerAdvice @ControllerAdvice Spring-managed beans were detected. @param handlerMethod the method where the exception was raised raised, possibly {@code null} @param exception the raised exception @return a method to handle the exception, or {@code null}
Class ExceptionHandlerExceptionResolver, HandlerMethodReturnValueHandlerComposite getReturnValueHandlers()

Return the configured handlers, or possibly {@code null} if notnot initialized yet via .afterPropertiesSet().
Class ExceptionHandlerExceptionResolver, void setCustomArgumentResolvers(List<HandlerMethodArgumentResolver>)

Provide resolvers for custom argument types. Custom resolvers are ordered after built-in ones. To override the built-in support for argument argument resolution use .setArgumentResolvers instead.
Class ExceptionHandlerExceptionResolver, void setReturnValueHandlers(List<HandlerMethodReturnValueHandler>)

Configure the complete list of supported return value types thusthus overriding handlers that would otherwise be configured by default.

Class PathVariableMethodArgumentResolver

Resolves method arguments annotated with an @PathVariable.

An @PathVariable is a named value that gets resolved from a URIURI template variable. It is always required and does not have a default valuevalue to fall back on. See the base classclass org.springframework.web.method.annotation.AbstractNamedValueMethodArgumentResolver for more information on how named values are processed.

If the method parameter type is Map, the name specified in the annotation is used to resolve the URI variable String value. The value is then converted to a Map via type conversion assuming a suitable Converter or PropertyEditor has been registered. Or if the annotation does not specify name the RequestParamMapMethodArgumentResolver is used instead to provide access to all URI variables in a map.

A WebDataBinder is invoked to apply type conversion to resolved path variable values that that don't yet match the method parameter type. @author Rossen Stoyanchev @author Arjen Poutsma @since 3.1


Class RequestMappingHandlerMapping, RequestCondition<?> getCustomMethodCondition(Method)

Provide a custom method-level request condition. The custom RequestCondition can be of any type so long as the same condition type is returned from all calls to this method in order to ensure custom request conditions can be combined and compared.

Consider extending AbstractRequestCondition for custom condition types and using CompositeRequestCondition to provide multiple custom conditions. @param method the handler method for which to create the condition @return the condition, or {@code null}

Class RequestMappingHandlerMapping, RequestCondition<?> getCustomTypeCondition(Class<?>)

Provide a custom type-level request condition. The custom RequestCondition can be of any type so long as the same condition type is returned from all calls to this method in order to ensure custom request conditions can be combined and compared.

Consider extending AbstractRequestCondition for custom condition types and using CompositeRequestCondition to provide multiple custom conditions. @param handlerType the handler type for which to create the condition @return the condition, or {@code null}

Class RequestMappingHandlerMapping, void setUseSuffixPatternMatch(boolean)

Whether to use suffix pattern match (".*") when matching patterns to requests. If enabled a method mapped to "/users" also matches to "/users.*".

The default value is {@code true}.

Also see .setUseRegisteredSuffixPatternMatch(boolean) for more fine-grained control over specific suffixes to allow.


Class RequestPartMethodArgumentResolver

Resolves the following method arguments:

When a parameter is annotated with {@code @RequestPart} the content of the the part is passed through an HttpMessageConverter to resolve the method method argument with the 'Content-Type' of the request part in mind. This is is analogous to what @RequestBody does to resolve an argument based on the content of a regular request.

When a parameter is not annotated or the name of the part is not specified, it is derived from the name of the method argument.

Automatic validation may be applied if the argument is annotated with with {@code @javax.validation.Valid}. In case of validation failure, a a MethodArgumentNotValidException is raised and a 400 response status code returned if DefaultHandlerExceptionResolver is configured. @author Rossen Stoyanchev @since 3.1


Class RequestResponseBodyMethodProcessor

Resolves method arguments annotated with {@code @RequestBody} and handleshandles return values from methods annotated with {@code @ResponseBody} by reading and writing to the body of the request or response with an an HttpMessageConverter.

An {@code @RequestBody} method argument is also validated if it is is annotated with {@code @javax.validation.Valid}. In case of validation validation failure, MethodArgumentNotValidException is raised and results results in a 400 response status code if DefaultHandlerExceptionResolver is configured. @author Arjen Poutsma @author Rossen Stoyanchev @since 3.1


Class ServletModelAttributeMethodProcessor

A Servlet-specific org.springframework.web.method.annotation.ModelAttributeMethodProcessor that applies data binding through a WebDataBinder of type ServletRequestDataBinder.

Also adds a fall-back strategy to instantiate the model attribute from a URI template variable or from a request parameter if the name matches the model attribute name and there is an appropriate type conversion strategy. @author Rossen Stoyanchev @since 3.1

Class ServletModelAttributeMethodProcessor, constructor ServletModelAttributeMethodProcessor(boolean)

@param annotationNotRequired if "true", non-simple method arguments and return values are considered model attributes with or without aa {@code @ModelAttribute} annotation.
Class ServletModelAttributeMethodProcessor, Object createAttribute(String, MethodParameter, WebDataBinderFactory, NativeWebRequest)

Instantiate the model attribute from a URI template variable or from a request parameter if the name matches to the model attribute name and if there is an appropriate type conversion strategy. If none of these are true delegate back to the base class. @see #createAttributeFromUriValuecreateAttributeFromRequestValue(String, String, MethodParameter, WebDataBinderFactory, NativeWebRequest)
Class ServletModelAttributeMethodProcessor, Object createAttributeFromRequestValue(String, String, MethodParameter, WebDataBinderFactory, NativeWebRequest)

Create a model attribute from a String request value (e.g. URI template variable, request parameter) using type conversion.

The default implementation converts only if there a registeredregistered Converter that can perform the conversion. @param sourceValue the source value to create the model attribute from @param attributeName the name of the attribute, never {@code null} @param parameter the method parameter @param binderFactory for creating WebDataBinder instance @param request the current request @return the created model attribute, or {@code null} @throws Exception

Class ServletModelAttributeMethodProcessor, String getRequestValueForAttribute(String, NativeWebRequest)

Obtain a value from the request that may be used to instantiate the model attribute through type conversion from String to the target type.

The default implementation looks for the attribute name to match a URI variable first and then a request parameter. @param attributeName the model attribute name @param request the current request @return the request value to try to convert or {@code null}