Service in Android
Service in Android
Service is one of the most important components. Basically service is a long running process in background without needing with user interaction. If application are destroyed also service is running. Service is not a thread.It not have a user interface.
A service can handle network transactions, play music, perform file I/O, or interact with a content provider, all from the background.
Diff b/w Service, AsyncTask and Thread
Service- Service is one of the most important components. Basically service is a long running process in background without needing with user interaction. If application are destroyed also service is running. Service is not a thread.It not have a user interface.
A service can handle network transactions, play music, perform file I/O, or interact with a content provider, all from the background.
AsyncTask- AsyncTask enables proper and easy use of the UI thread. This class allows you to perform background operations and publish results on the UI thread without having to manipulate threads or handlers.
Threads- Moving numerous or long tasks from the main thread, so that they don’t interfere with smooth rendering and fast responsiveness to user input,is the biggest reason for you to adopt threading in your app.
Service is one of the most important components. Basically service is a long running process in background without needing with user interaction. If application are destroyed also service is running. Service is not a thread.It not have a user interface.
A service can handle network transactions, play music, perform file I/O, or interact with a content provider, all from the background.
Diff b/w Service, AsyncTask and Thread
Service- Service is one of the most important components. Basically service is a long running process in background without needing with user interaction. If application are destroyed also service is running. Service is not a thread.It not have a user interface.
A service can handle network transactions, play music, perform file I/O, or interact with a content provider, all from the background.
AsyncTask- AsyncTask enables proper and easy use of the UI thread. This class allows you to perform background operations and publish results on the UI thread without having to manipulate threads or handlers.
Threads- Moving numerous or long tasks from the main thread, so that they don’t interfere with smooth rendering and fast responsiveness to user input,is the biggest reason for you to adopt threading in your app.
Comments
Post a Comment