用Android studio写下面这段代码运行时会闪退,求指教
用Android studio写下面这段代码运行时会闪退,求指教
private List<Map<String,Object>> getData(){ for(int i=0;i<20;i++){ Map<String,Object> map=new HashMap<String,Object>(); map.put("imageView",R.drawable.ic_launcher); map.put("textV iew","公仔"+i); datalist.add(map); } return datalist; }