O'Reilly logo

Android 5 Programming by Example by Kyle Mew

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 4. Managing RecyclerViews and Their Data

In the previous chapter, we saw how to work with more than one Activity, but the data displayed in both was static. To progress, we need a way to apply a choice of data to a predefined layout and ideally present this as part of a list. Android 5 has introduced the RecyclerView-a more efficient and flexible version of the previously used ListView. To implement a RecyclerView, we will need a LayoutManager, an Adapter and some data to work with. In this chapter, we will start a new app that creates a list of CardViews, each displaying the relevant data and serving as a link to more detailed information.

In this chapter, we will cover the following topics:

  • Creating a RecyclerView
  • Designing a CardView Layout ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required