Components of Android Apps
Activity applies the presentation layer, and every UI in an application is implemented through the activity class or multiple extensions. Activity uses fragment and views to lay out and display information, as well as respond to user actions. (The activity in the desktop development environment is equivalent to the from) workers that are not visible in the service application. Service components do not have a UI at run time, they can update data sources and activity, trigger notifications, and broadcast intent. They are used to perform some long-running tasks or tasks that do not require user interaction. Content provider A shareable persistent data memory. Content provider is used to manage and persist application data, typically interacting with SQL databases. Content provider is the preferred method for sharing data between applications. You can configure your own content provider to allow other applications to access, or you can access the content provider provided by other applications. Intent a powerful messaging framework between applications. Intent is used extensively in Android. Intent can be used to start or stop activity and service, to broadcast messages to target activity, service or broadcast receiver, and to request a specific piece of data to perform operations within the system scope. Broadcast receiver Intent listener. Broadcast receiver enables applications to listen to intent broadcasts that match the specified filtering criteria. Broadcast receiver automatically launches the application to respond to a received intent, which makes them the best choice for event-driven applications. Widgets are typically added to the visual application component of the device home screen. Widgat is a special variant of broadcast receiver that can be used to create dynamic, interactive application components that users can add to their home screen. Notification notification allows signals to be sent to the user, but does not unduly attract their attention or disrupt their current activity. They are the preferred method of attracting user attention when the application is not visible or inactive.
Parts of an Android application