把这段JAVA代码转换成Asp.net C# 10
privateStringcontentMD5(HttpEntityEnclosingRequestBasehttpMethod){ByteArrayOutputStre...
private String contentMD5(HttpEntityEnclosingRequestBase httpMethod) {
ByteArrayOutputStream requestOutputStream = new ByteArrayOutputStream();
try {
httpMethod.getEntity().writeTo(requestOutputStream);
} catch (IOException e) {
System.out.println("ERROR: IOException caught when writing Content MD5 hash");
e.printStackTrace();
}
return DigestUtils.md5Hex(requestOutputStream.toByteArray()).toLowerCase();
} 展开
ByteArrayOutputStream requestOutputStream = new ByteArrayOutputStream();
try {
httpMethod.getEntity().writeTo(requestOutputStream);
} catch (IOException e) {
System.out.println("ERROR: IOException caught when writing Content MD5 hash");
e.printStackTrace();
}
return DigestUtils.md5Hex(requestOutputStream.toByteArray()).toLowerCase();
} 展开
1个回答
2015-12-03
展开全部
可以在文件的最开始加上这么一句话:
#define _CRT_SECURE_NO_WARNINGS
#define _CRT_SECURE_NO_WARNINGS
追问
答非所问
本回答被网友采纳
已赞过
已踩过<
评论
收起
你对这个回答的评价是?
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询