Book Image

Mastering Android Studio 3

By : Kyle Mew
Book Image

Mastering Android Studio 3

By: Kyle Mew

Overview of this book

Android Studio is an Integrated Development Environment (IDE) designed for developing Android apps. As with most development processes, Android keeps resources and logic nicely separated, and so this book covers the management of imagery and other resources, and the development and testing tools provided by the IDE. After introducing the software, the book moves straight into UI development using the sophisticated, WYSIWYG layout editor and XML code to design and test complex interfaces for a wide variety of screen configurations. With activity design covered, the book continues to guide the reader through application logic development, exploring the latest APIs provided by the SDK. Each topic will be demonstrated by working code samples that can be run on a device or emulator. One of Android Studio's greatest features is the large number of third-party plugins available for it, and throughout the book we will be exploring the most useful of these, along with samples and libraries that can be found on GitHub. The final module of the book deals with the final stages of development: building and distribution. The book concludes by taking the reader through the registration and publication processes required by Google. By the time you have finished the book, you will be able to build faster, smoother, and error-free Android applications, in less time and with fewer complications than you ever thought possible.
Table of Contents (10 chapters)

Workspace Structure

Android Studio is a powerful and sophisticated development environment, designed with the specific purpose of developing, testing, and packaging Android applications. It can be downloaded, along with the Android SDK, as a single package, but as we shall see throughout the course of this book, it is, in reality, a collection of tools and components, many of which are installed and updated independently of each other.

Android Studio is not the only way to develop Android apps; there are other IDEs, such as Eclipse and NetBeans, and it is even possible to develop a complete app using nothing more than Notepad and the command line, although this last method would be very slow and cumbersome.

Whether you are migrating from another IDE or just want to get the most from Android Studio, this book will take you through all of its most useful features in the order that these would be encountered during the course of developing an application, starting with UI development and progressing through coding and testing to building and distribution. Android Studio provides some useful and smart tools to assist us at every step of this journey.

Built for a purpose, Android Studio has attracted a growing number of third-party plugins that provide a large array of valuable functions, not available directly via the IDE. These include plugins to speed up build times, debug a project over Wi-Fi, and many more. The most useful and popular of these will be covered in the relevant sections. Throughout the book, we will be finding ways to speed up tedious and difficult tasks using these plugins and Android Studio's built in components.

In this chapter, you will be engaged with the following topics:

  • Exploring the differences between Studio and other IDEs
  • Taking a brief guided tour
  • Learning how the workspace is structured
  • Exploring editor windows
  • Creating a Material theme
  • Understanding Tools windows
  • Exploring device filesystems
  • Using Instant Run to speed up the build process
  • Exploring the SDK manager
  • Introducing the virtual device manager
  • Importing a project from another IDE
Android Studio

If you are already familiar with Android Studio, then you may wish to skip some sections of this introductory chapter, as it is written more with those migrating from other IDEs in mind. However, there are a number of handy tips that you may not have come across before.

Despite being arguably a superior tool, there are some very good reasons for having stuck with another IDE, such as Eclipse. Many developers develop for multiple platforms, which makes Eclipse a good choice of tool. Every developer has deadlines to meet, and getting to grips with unfamiliar software can slow them down considerably at first. This book will speed up this transition so that migrating developers can begin to take advantage of the added features provided by Android Studio with as little interruption as possible.