For an Android appProgramIt consists of four parts:
- Activity
- Intent receiver er
- Service
- Content Provider
Once you determine which components are used, you need to list them in androidmanifest. xml.
Activity
An activity is almost a view (screen ). Every activity is a class inherited from the activity base class, which is composed of view and Event Response. When you move to another view, a new activity is started. When the new view is started, the previous view is paused (a State of the activity lifecycle) and is pushed into the history stack (used to store the stack of the user activity ).
Intent and intentfilter
Intent is a collection of actions and content. Intent is like a URL, which is sent to the system and used by other activities to process the actions and content specified in the URL.
Service
To process Background processes, Android introduces the concept of service. Service is a long-lived component in Android, which does not implement any user interface. The most common example is the media player program. It can still play songs when it is switched to the background. or, for example, the file download program can download files in the background.
Content Provider
Android applications can use files or sqllite databases to store data. Content provider provides a way to share data between multiple applications. For example, contact information can be accessed by multiple applications. Content Provider is a class that implements a set of standard methods used to provide data access for other applications. The application can perform the following operations in the content provider: query data, modify data, add data andDelete data