I am seeking an example of something that can be done with an IntentService
that cannot be done with a Service
(and vice-versa)?
I also bel
The Major Difference between a Service
and an IntentService
is described as follows:
Service :
1.A Service
by default, runs on the application's main thread.(here no default worker thread is available).So the user needs to create a separate thread and do the required work in that thread.
2.Allows Multiple requests at a time.(Multi Threading)
IntentService :
1.Now, coming to IntentService
, here a default worker thread is available to perform any operation. Note that - You need to implement onHandleIntent()
method ,which receives the intent for each start request, where you can do the background work.
2.But it allows only one request at a time.