Android ListView 适配器notifyDataSetInvalidated() 与notifyDataSetChanged()
有什么区别? android文档没有notifyDataSetInvalidated()的描述。我在想也许您调用该函数来通知所有已注册的侦听器,但使用 notifyDataSetChanged() 来不通知它们?
What is the difference? The android documentation doesn't have a description for notifyDataSetInvalidated(). I was thinking maybe you call that function to notify all registered listeners, but use notifyDataSetChanged() to not notify them?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
更改意味着数据集已更改。更新了单个项目,或者添加或删除了项目。无效意味着数据源不再可用。
Changed means the data set changed. Individual items updated, or items were added or removed. Invalidated means the data source is no longer available.