question archive Describe briefly the three fundamental components of an Android application

Describe briefly the three fundamental components of an Android application

Subject:Computer SciencePrice:2.89 Bought3

Describe briefly the three fundamental components of an Android application.

pur-new-sol

Purchase A New Answer

Custom new solution created by our subject matter experts

GET A QUOTE

Answer Preview

The three fundamental components of an Android application are:

1. Activities: An activity is a class that is considered as an entry point for users that represents a single screen. A messenger application might have an activity that shows a new notification/message, another activity that reads messages, and another which composes a new message.

Each activity is independent of one another.

To implement an activity, extend the Activity class in your subclass:

public class MyActivity extends Activity {
//code
}


2. Services: A service is a component that runs in the background, it acts as an invisible worker for our application. It keeps updating data sources and activities. It also broadcasts intents and performs tasks when applications are not active. An example of a service is we can surf the internet or use any other application while listening to music.

To execute services, extend the Services class in your sub-class:

public class MyService extends Services {
//code
}


3. Content Providers: Content Provider is a component that allows applications to share data among multiple applications. It hides the details of the database and can be used to read and write private data of the application which is not shared. It would be a mess to access data from other applications without content providers.

For example – you can consider looking for contact details in the contact list, or you might want photos from the gallery which are also provided by Content Provider.