title: IOS How do I asynchronously download and cache images and videos for use in my app
body: <p>I have an iphone application that displays both images and videos. The way the app is structured most of the images and videos will remain the same, with one occasionally added. I would like an opinion on the best and easiest method for asynchronously downloading and caching both images and videos, so that they will persist even after the application has quit. Also, I am only really concerned with IOS 5 and later.</p>
  
  <p>Here is some information I have found thus far, but I am still unclear about what the best method is, and if the cache will be persistent.</p>
  
  <p><a href="http://davidgolightly.blogspot.com/2009/02/asynchronous-image-caching-with-iphone.html" rel="nofollow noreferrer">This article</a> about asynchronous image caching (old 2009)</p>
  
  <p><a href="http://petersteinberger.com/blog/2012/nsurlcache-uses-a-disk-cache-as-of-ios5/" rel="nofollow noreferrer">This article</a> about NSURLCache</p>
  
  <p><a href="https://github.com/rs/SDWebImage" rel="nofollow noreferrer">SDWebImage</a> (looks great but only works with images)</p>
  
  <p><a href="https://github.com/steipete/AFDownloadRequestOperation" rel="nofollow noreferrer">AFDownloadRequestOperation</a></p>
  
  <p>This seems like a pretty common use case, so I'm really looking for best practices and or references to example code.</p>