In applications intended for Android systems, the components of the applications are displayed to users when long and complex processes are performed. In this case, services are used. In other words, it can be said that when long-term processing needs to be done in the background and users can see them. It should be noted that services are one of the components that are most used in Android systems and are also used in more times when long and repetitive processing is done in the background ofthe Android system. What we mean by running in the background is that when the user even closes the application and opens another application, it runs again in the background. That is, when the application is closed, its activity is not interrupted, and it continues to operate behind the scenes or in the background. In short, we can say that services have no dependence on the life cycle of activities and can continue to operate without the need for them.Closing or opening the application and the desired program can not have any effect on the activity of services; This means that whether the program or application is open or closed, the service will continue to operate.To better understand this issue, we will give you examples so that you can easily understand and understand them.Consider a situation where, for example, a user has opened a song in a music player. In this case, when the user wants to go to other activities or open another activity, the music that was playing will stop. But the user wants the music to continue playing and the user can safely go to other activities and work with them. In this case, the services will help and continue their activities in the background.In another example, consider the situation where the user wants to download a file, in which case the user must wait for the long download process to complete and then be able to go to other activities. This is tedious and tedious work, so we use the services so that we can continue long-term activities in the background and while continuing their activities in the background to other activities. When you use the Download Manager to download a file, you no longer must wait for the process to complete so that you can go to other activities, in which case you can activate other activities and use them at the same time as the Download Manager download process. By leaving this program, the download process will not stop, and users can easily continue their activities in other activities.

What are the different types of services in Android systems?

Services in Android systems are of two types:

1- Started Services

2- Bound Services

Started Services:

Started Servicesis related to the tasks that are defined for it, in that they only do the tasks that are intended for it and after that it does not do any other work. In other words, it is used to perform the intended activities and after completing that activity, it is no longer engaged in any other activity. It only does what it is supposed to do. It should be noted that this type of service is started by calling the startService and startForegroundService methods and its stopping is done by calling the stopService or stopSelf methods. In other words, we can say that in this type of service we can only use intent to start and stop services and we cannot have any other control and management on them. This service only allows us to start and stop, not to manage and control.

Read more on:https://www.dotnek.com/Blog/Apps/what-are-the-services-in-android-systems-and

link:https://dotnek.mystrikingly.com/

Related link:DOTNEK BLOG

How to start learning Android development

Android article,How to work with cameras on Android devices in two ways

Android article,What are BroadcastReceiver in Android systems, why and how to use them?

Android article,What are floating buttons in Android systems and how can they be used?

Android article,How can we change the font in Android and how to solve different problems?

Android article,What are snackbars in Android systems and how can they be used?

Android article,What are the services in Android systems and when are they used?

the ,in ,and ,to ,that ,services ,the background ,in the ,other activities ,the user ,android systems ,continue their activities

مشخصات

آخرین ارسال ها

آخرین جستجو ها


میرممد فانوس فروشگاه اینترنتی toshakmarket معرفی برترین سایت های خدماتی آدخت دانلود بانک لینک های دانلود فیلم ، دانلود سریال و دانلود آهنگ میباشد. تخفیف ویژه فقط برای امروز طراحی سایت retusemi migration2018
دزدگ