Class MappingAwareDefaultedPageableArgumentResolver
java.lang.Object
org.springframework.data.rest.webmvc.json.MappingAwareDefaultedPageableArgumentResolver
- All Implemented Interfaces:
HandlerMethodArgumentResolver
public class MappingAwareDefaultedPageableArgumentResolver
extends Object
implements HandlerMethodArgumentResolver
HandlerMethodArgumentResolver
to resolve DefaultedPageable
from a
PageableHandlerMethodArgumentResolver
applying field to property mapping.
A resolved DefaultedPageable
is post-processed by applying Jackson field-to-property mapping if it contains a
Sort
instance. Customized fields are resolved to their property names. Unknown properties are removed from
Sort
.
- Since:
- 2.6
- Author:
- Mark Paluch, Oliver Gierke
-
Constructor Summary
ConstructorDescriptionMappingAwareDefaultedPageableArgumentResolver
(JacksonMappingAwareSortTranslator translator, PageableHandlerMethodArgumentResolver delegate) -
Method Summary
Modifier and TypeMethodDescriptionresolveArgument
(MethodParameter parameter, ModelAndViewContainer mavContainer, NativeWebRequest webRequest, WebDataBinderFactory binderFactory) boolean
supportsParameter
(MethodParameter parameter)
-
Constructor Details
-
MappingAwareDefaultedPageableArgumentResolver
public MappingAwareDefaultedPageableArgumentResolver(JacksonMappingAwareSortTranslator translator, PageableHandlerMethodArgumentResolver delegate)
-
-
Method Details
-
supportsParameter
- Specified by:
supportsParameter
in interfaceHandlerMethodArgumentResolver
-
resolveArgument
public Object resolveArgument(MethodParameter parameter, ModelAndViewContainer mavContainer, NativeWebRequest webRequest, WebDataBinderFactory binderFactory) throws Exception - Specified by:
resolveArgument
in interfaceHandlerMethodArgumentResolver
- Throws:
Exception
-