2016年5月13日
摘要: for(1;2;3) 4 执行顺序1,2,4,3;一句话时可以省略{}. switch(xx){case xx:... break};执行完之后别忘break,不然会有case穿透;switch只能探测到int类型的值;没有符合case会执行defalut;case 1: case 2: case 阅读全文
posted @ 2016-05-13 13:49 微笑流氓兔 阅读(169) 评论(0) 推荐(0) 编辑
  2016年5月12日
摘要: xmlstr转化为对象 XStream xstream=new XStream(); xstream.autodetectAnnotations(true); xstream.alias("User",User.class); (User)xstream.fromXML(xmlstr); 对象转化为 阅读全文
posted @ 2016-05-12 17:51 微笑流氓兔 阅读(183) 评论(0) 推荐(0) 编辑
摘要: 1、JSONObject.fromObject(jsonstr); 2、JSONArray.fromObject(jsonstr); 阅读全文
posted @ 2016-05-12 16:42 微笑流氓兔 阅读(219) 评论(0) 推荐(1) 编辑
摘要: 阅读全文
posted @ 2016-05-12 15:42 微笑流氓兔 阅读(136) 评论(0) 推荐(0) 编辑