Search code examples
androidandroid-serviceandroid-contentproviderandroid-loader

What is best approach for android app with remote data?


I develop simple information application what display data from remote host. Data come via http in json or xml format. What is best modern approach for that: service, content-provider, loader or simple asynctask?


Solution

  • None of the above, use Robospice and Spring for Android, here is an infographic: https://raw.github.com/octo-online/robospice/master/gfx/RoboSpice-InfoGraphics.png

    Basically it will handle reading JSon, proper lifecycle management, and no memory leaks!