How to implement getFilter on a BaseAdapter?

前端 未结 7 813
半阙折子戏
半阙折子戏 2020-12-06 03:55

I am trying to implement a getFilter() on a base adapter to filter out search results on a List. Is there any example of how to implement a getFilter()?

MainActivity

7条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-06 04:09

    You need to return an instance of a Filter. To write a filter, subclass Filter and implement performFiltering and publishResults. See the docs.

提交回复
热议问题