0
我与json的Struts2的工作,我的工作就是.NET代码转换成Java我在将下面的代码挣扎,是任何对象调用JSON不使用响应,并要求发布响应
//clears the existing HTML
Response.Clear();
//change content type
Response.ContentType = CommonConstants.Common.CONTENT_TYPE_TEXT_PLAIN;
Response.Write(strJSON.ToString());
//writes out the new name
Response.End();
上面的代码是.net我努力转换为Java。因为我不应该使用HttpServletRequest或HttpServletResponse对象。
在此先感谢
不使用HttpServletResponse的,怎么可能u你的JSON发送到响应你的行动响应。我不认为它是可能的 – 2012-02-20 13:58:20
我不是100%确定的,所以我问你人们可能会知道一些东西谢谢你 – MohanMaverick 2012-02-20 14:00:34