Book Image

Android Studio 3.5 Development Essentials - Java Edition

By : Neil Smyth
Book Image

Android Studio 3.5 Development Essentials - Java Edition

By: Neil Smyth

Overview of this book

Android applications have become an important part of our daily lives and lots of effort goes into developing an Android application. This book will help you to build you own Android applications using Java. Android Studio 3.5 Development Essentials – Java Edition first teaches you to install Android development and test environment on different operating systems. Next, you will create an Android app and a virtual device in Android Studio, and install an Android application on emulator. You will test apps on physical Android devices, then study Android Studio code editor and constraint layout, Android architecture, the anatomy of an Android app, and Android activity state changes. The book then covers advanced topics such as views and widgets implementation, multi-window support integration, and biometric authentication, and finally, you will learn to upload your app to Google Play console and handle the build process with Gradle. By the end of this book, you will have gained enough knowledge to develop powerful Android applications using Java.
Table of Contents (86 chapters)
86
Index

48.1 Adding Sample Data to a Project

During the design phase of the user interface layout, the RecyclerView instance (Figure 48-1) bears little resemblance to the running app tested at the end of the previous chapter:

Figure 48-1

In the “Modern Android App Architecture with Jetpack” chapter earlier in the book the concept of sample data was introduced. To demonstrate sample data in use, the project will now be modified so that the fully populated cards appear within the RecyclerView from within the layout editor. Before doing that, however, it is worth noting that the layout editor has a collection of preconfigured sample data templates that can be used when designing user interfaces. To see some of these in action, load the content_main.xml layout file into the layout editor and select the RecyclerView instance. Right-click on the RecyclerView and select the Set Sample Data menu option to display the Design-time View Attributes panel:

Figure 48-2

...