springBoot获取httpServletRequest,转化为字符串

public String getHttpServletRequestToString(HttpServletRequest request){
//StreamUtils为springframework包的工具类
	return StreamUtils.copyToString(request.getInputStream(), Charset.forName(Charsets.UTF_8.name()));
}

你可能感兴趣的:(JAVA技术,java,spring,字符串)