JAVA基础累积之HttpServletRequest

请求地址:http://10.10.6.179:8080/sheji/sso?detailUrl=preInfo/preChartinfo/sjform=DesignCompanyApprovalForm?xiangmubianhao=HC010016&jiaofuwubianhao=163064


String newFilePath = request.getRealPath("/") + "static/pdf/pdfFile/11.pdf";

控制台输出:D:\eclipse\allotList\.metadata\.plugins\org.eclipse.wst.server.core\tmp39\wtpwebapps\sheji\static/pdf/pdfFile/11.pdf

String queryString = request.getQueryString();

控制台输出:detailUrl=preInfo/preChartinfo/sjform=DesignCompanyApprovalForm?xiangmubianhao=HC010016&jiaofuwubianhao=163064

String requestURI = request.getRequestURI();

控制台输出:/sheji/sso

String requestURL = request.getRequestURL().toString();

控制台输出:http://10.10.6.179:8080/sheji/sso

String remoteAddr = request.getRemoteAddr();

控制台输出:10.10.6.179

String remoteHost = request.getRemoteHost();

控制台输出:10.10.6.179

int remotePort = request.getRemotePort();

控制台输出:50619

String remoteUser = request.getRemoteUser();

控制台输出:com.openeap.modules.sys.security.SystemAuthorizingRealm$Principal@6109ba92


你可能感兴趣的:(JAVA基础累积之HttpServletRequest)