@InjectHttpErr(value = {1, 3}) public void resultErr(ResponseEntity r) { dismissDialog(); Ioc.getIoc().getLogger().i("接口请求异常:" + r.getContentAsString()); if (r.getKey() == 1) { pageUtil.isEndDownPage(); Toast.makeText(activity, ErrorMsgEnum.NET_ERROR.getName(), Toast.LENGTH_SHORT).show(); } }
/** * *********************************************** @Title: initData @Description: TODO(组装数据) * * @param list * @param page 设定文件 * @return void 返回类型 * @throws * @date 2015-2-6 *********************************************** */ private void initData(ArrayList<HashMap<String, String>> list, String page) { pageUtil.isEndDownPage(); if (null != list && list.size() > 0) { HashMap<String, String> m = null; if ("1".equals(page)) { datalist.clear(); } ArrayList<HashMap<String, String>> datas = new ArrayList<HashMap<String, String>>(); for (HashMap<String, String> map : list) { m = new HashMap<String, String>(); m.put("tx_content_url", map.get("msgCntUrl")); m.put("tx_msg_title", map.get("msgTitle")); m.put("tx_msg_content", ""); m.put("tx_msg_time", DateUtil.formatDateToDay(map.get("msgTime"))); datalist.add(m); } datalist.addAll(datas); adapter.notifyDataSetChanged(); } }