@Override protected Map getInParameters(HttpServletRequest request, Object handler, Method method) { String accessUri = URIUtil.getAccessUri(request); String methodUri = getMethodUri(handler, accessUri); String methodUriAndPar = method.getAnnotation(RequestMapping.class).value(); Map<String, String[]> parametersForRest = URIUtil.getParametersForRest(methodUri, methodUriAndPar); Map<String, String[]> parameters = request.getParameterMap(); parametersForRest.putAll(parameters); return parametersForRest; }
protected Method getMethod(Object handler, HttpServletRequest request) { String accessUri = URIUtil.getAccessUri(request); String methodUri = getMethodUri(handler, accessUri); Method[] methods = handler.getClass().getMethods(); for (int i = 0; i < methods.length; i++) { String methodUriAndPar = methods[i].getAnnotation(RequestMapping.class).value(); if (URIUtil.isMatchForRest(methodUri, methodUriAndPar)) { return methods[i]; } } log.warn("The Controller of " + accessUri + "does not hava method of " + methodUri); return null; }