java.lang.IndexOutOfBoundsException: Index: 0, Size: 0

今天寫練習的時候出現一個bug,就是下拉列表切換然後下拉刷新出現閃退,報錯是java.lang.IndexOutOfBoundsException: Index: 0, Size: 0,然後查了一堆資料最後發現我adaptre.getData().clear();以後沒有刷新adaptre.notifyDataSetChanged();,導致越界
相關文章
相關標籤/搜索