All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.yt.web.utils.WebUtils Maven / Gradle / Ivy

There is a newer version: 3.0.1
Show newest version
package com.github.yt.web.utils;


import javax.servlet.http.HttpServletRequest;

public class WebUtils extends org.springframework.web.util.WebUtils {

    /**
     * 获取url和request参数
     */
    public static String getParameterValues(HttpServletRequest request) {
        Object pathVariables = request.getAttribute("org.springframework.web.servlet.View.pathVariables");
        String parameterValues = org.springframework.web.util.WebUtils.getParametersStartingWith(request, null).toString();
        if (pathVariables == null) {
            pathVariables = "{}";
        }
        return "parameterValues:" + parameterValues + ",pathVariables:" + pathVariables;
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy