2012年6月2日
摘要: 项目返回格式是JSON,用JSONObject解析后发现顺序乱了,原因是JSONObject类用的是HashMap网上说改成改为LinkedHashMap就OK了,因为HaspMap是无序,LinkedHashMap是有序的。改这个要修改源代码,本人不知道怎么修改.自己写的解析JSON格式 代码如下 阅读全文
posted @ 2012-06-02 13:42 freexiaoyu 阅读(27267) 评论(1) 推荐(0) 编辑
摘要: /** * * unicode 转换成 中文 * @param theString * @return */ public static String decodeUnicode(String theString) { char aChar; int len = theString.length(); StringBuffer outBuffer = new StringBuffer(len); for (int x = 0; x < len;) { aChar = theString.charAt(x++); if (aChar == '\\') { aCh... 阅读全文
posted @ 2012-06-02 11:51 freexiaoyu 阅读(12898) 评论(0) 推荐(0) 编辑