This might be the expected behavior, but is not clearly stated by Apple.
I am using NSCache
to cache some images for my UICollectionView
. When I put the app in the background and open it again (immediately), all of my images are no longer in the NSCache
.
Ideally, I would like the most recently loaded images to stay cached so that when the user re-opens the app they don't have to pay the cost of loading all of the images again. It seems like NSCache
should allow a less aggressive caching policy.
I just wanted to post here for a sanity check and make sure I'm not missing anything obvious.
Otherwise, I'm going to have to implement my own cache that just keeps the last 25 loaded images in an NSMutableDictionary
cache.