Câu hỏi phỏng vấn Android
Câu hỏi

What is the difference between ListView and RecyclerView ?

Câu trả lời

Here is a comparison of ListView and RecyclerView in Android:

ListView

  • Older view for displaying scrollable lists of items
  • Requires implementing an Adapter to provide the data for each list item
  • Adapter needs to implement getView() to return a View for each position
  • Reuses views that scroll off screen to improve performance
  • Requires manually managing view recycling and reuse
  • Limited to vertical scrolling only

RecyclerView

  • Newer, more flexible and powerful list view
  • Requires implementing an Adapter to provide the data for each list item
  • Adapter needs to implem...
middle

middle

Gợi ý câu hỏi phỏng vấn

middle

What is the difference between Adapter and Loader in Android?

middle

What is the difference between onCreate() and onCreateView() lifecycle methods in Fragment ?

middle

Describe different types of Services in Android

Bình luận

Chưa có bình luận nào

Chưa có bình luận nào