2017-10-27 16:22
@JFinal 我没有close,但是到Controller就没有得到流的内容了。
public static String getParam(HttpServletRequest request) {
StringBuffer out = new StringBuffer();
byte[] b = new byte[4096];
try {
for (int n; (n = request.getInputStream().read(b)) != -1;) {
out.append(new String(b, 0, n));
}
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return out.toString();
}