Store custom ListView locally from Azure Database

时间:2015-11-12 11:52:09

标签: android listview azure local

I have an Activity which displays a custom ListView of a class called Comments. Comments have a title, a body and a date and the ListView displays all of them. The comments are being stored in an Azure Database through an Azure Mobile Service. So every time the Activity is opened I fetch the comments with an AsyncTask on the background thread. But this way the comments have to be downloaded every time the user opens the Activity. What I want to do is store the comments locally so when the user opens the activity there are some comments that appear instantly while I fetch the newest comments and display them when they are ready. An example would be very helpful. Thanks.

1 个答案:

答案 0 :(得分:1)

从Azure团队中查看此tutorial,您就可以了。