Image Caching from http sources

◇◆丶佛笑我妖孽 提交于 2019-12-08 12:13:36

问题


I've read in a post from December 1st 2012 at Slodge bloch that File and DownloadCache plugins could be used for downloading and caching images from http sources. I think that's what I need in the app I'm trying to develop with MvvmCross (great framework, congratulations!!).

My app, first connects to a remote server to download some basic configs. One of these configs points to an url to get the app icon. To save bandwith, I'd like app caches the icon the first time it gets it until the url changes.

I performed some search with no much success and I'd like somone pointing me to a good demo on how to cache images from http sources and then binding these image to UI Image controls (Droid, iOS and WP)

Thaks


回答1:


Showing images on wp, winrt, xamarin.android and xamarin.touch from http is shown in these two N+1 videos:

  • Kittens - N=2 - https://www.youtube.com/watch?v=e-ZKgO8fTw4
  • Books - N=6 - https://www.youtube.com/watch?v=He6QvnLsPUA



回答2:


I've faced the same issue recently and finally solved it. It was pretty easy, you just need to make sure that you added and initialized Cirrious.MvvmCross.Plugins.Json plugin in your project.

I created a similar question that it's solved already https://stackoverflow.com/a/17891681/1309164



来源:https://stackoverflow.com/questions/16394389/image-caching-from-http-sources

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!