O'Reilly logo

Java for Android, Second Edition by Budi Kurniawan

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 25

Activities

In Chapter 24, “Getting Started with Android” you learned to write a simple Android application. It is now time to delve deeper into the art and science of Android application development. This chapter discusses one of the most important component types in Android programming, the activity.

The Activity Lifecycle

The first application component that you need to get familiar with is the activity. An activity is a window containing user interface (UI) components that the user can interact with. Starting an activity often means displaying a window.

An activity is an instance of the android.app.Activity class. A typical Android application starts by starting an activity, which, as I said, loosely means showing a window. ...

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