dimanche 5 juillet 2015

When I use a Bound Service in Android, does it run in the background, on its own thread or on the main UI thread?

I am searching through a dictionary in my app, and because it may takes some time, and involves searching through 170,000+ items, and inserting usually about 100 items into a database, etc..., I am trying to make it not hog the main thread. I have read conflicting things about bound services. Do they run on their own thread, or do I have to manually do that in the service? Basically, what do I have to do to run it in the background? I thought this was the whole point of a bound service. Any help would be greatly appreciated!

Aucun commentaire:

Enregistrer un commentaire