Android Basics – What is the Activity Lifecycle

Android Activity follows a Lifecycle from its time of creation till it gets destroyed. In this Article you will Learn about the Lifecycle.

As you can see in the attached diagram an Activity starts when its Launched. That’s the time its Constructor is run and object is created.

This is followed by the onCreate method which is responsible for Screen setup.

The next lifecycle method onStart gets called when the Activity becomes visible to the user.

Now an Activity can become invisible for a period of time. This is handled by the onStop method.

If an Activity becomes visible again then onRestart method is called.

Finally when an Activity gets destroyed then onDestroy is called.

Author: androidsmartly

I am a Tech Enthusiast who likes to work on new Ideas. Sharing knowledge on Android, Marketing, Startups and More.

1 thought on “Android Basics – What is the Activity Lifecycle”

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s