开发者

NSCache like class for iOS 3.0

I'm currently writing a application that would benefit extremely from caching, I'd like to use the NSCache class which delivers exactly what I want (in-memory caching with cost, key-value pairs, and automatic cleaning). However, NSCache is only available for iOS 4.0 and greater but I want to target iOS 3.0 too, so I can't use i开发者_JAVA技巧t (not caching on older devices is sadly not an option).

Before I start writing my own cache class, I want to know if there is an existing class that I could use (preferably not under an copy-left license).


Looks like there is no class that can do the same, I looked the last hours at every place for a caching class, but everything I saw were classes for on disk caching which is not what I want (I have already an on disk cache, but nothing for in memory).

Long story short, I decided to write my own caching class for this and I must say that it works surprisingly well.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜