@Override
public Object resolveArgument(MethodParameter parameter, ModelAndViewContainer mavContainer, NativeWebRequest webRequest, WebDataBinderFactory binderFactory) throws Exception {
PageableDefaults pageableDefaults = getPageableDefaults(parameter);
//默认的page request
Pageable defaultPageRequest = getDefaultFromAnnotationOrFallback(pageableDefaults);
String pageableNamePrefix = getPagePrefix(parameter);
String sortNamePrefix = getSortPrefix(parameter);
Map<String, String[]> pageableMap = getPrefixParameterMap(pageableNamePrefix, webRequest, true);
Map<String, String[]> sortMap = getPrefixParameterMap(sortNamePrefix, webRequest, false);
Sort sort = getSort(sortNamePrefix, sortMap, defaultPageRequest, webRequest);
if (pageableMap.size() == 0) {
return new PageRequest(defaultPageRequest.getPageNumber(), defaultPageRequest.getPageSize(), sort == null ? defaultPageRequest.getSort() : sort);
}
int pn = getPn(pageableMap, defaultPageRequest);
int pageSize = getPageSize(pageableMap, defaultPageRequest);