You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hello, I'm doing research on Android async programming. I see in Superuser, you use IntentService at some places (such as ResultService) while use AsyncTask at other places (such as in PreferencesActivity). I'm wondering how do you choose between AsyncTask and IntentService? because both are used to execute background tasks.
As far as I know, some articles (for example this article) mention that AsyncTask leads to memory leak and losing task result when there's a configuration change (such as orientation change). But using IntentService or AsyncTaskLoader can avoid such problems.
The text was updated successfully, but these errors were encountered:
Hello, I'm doing research on Android async programming. I see in
Superuser
, you useIntentService
at some places (such asResultService
) while useAsyncTask
at other places (such as inPreferencesActivity
). I'm wondering how do you choose betweenAsyncTask
andIntentService
? because both are used to execute background tasks.As far as I know, some articles (for example this article) mention that AsyncTask leads to memory leak and losing task result when there's a configuration change (such as orientation change). But using
IntentService
orAsyncTaskLoader
can avoid such problems.The text was updated successfully, but these errors were encountered: