LRImageManager icon indicating copy to clipboard operation
LRImageManager copied to clipboard

How to limit maximum cache memory?

Open xhzengAIB opened this issue 10 years ago • 3 comments

@luisrecuenco Hi! How to limit maximum cache memory?I look at the inside as if does not implement this feature

Jack

xhzengAIB avatar Sep 29 '14 15:09 xhzengAIB

You can use maxDirectorySize property of LRImageCache

luisrecuenco avatar Sep 29 '14 16:09 luisrecuenco

@luisrecuenco memory cache. the costLimit :https://github.com/tumblr/TMCache/blob/master/TMCache/TMMemoryCache.h#L44

https://github.com/tumblr/TMCache/blob/master/TMCache/TMMemoryCache.m#L184

When i set object to memory cache. will be check the max memory cache size. if current cache size > max memory cache size, it call clear memory method. not waiting the app did enter background call clear memory cache.

Jack

xhzengAIB avatar Sep 29 '14 17:09 xhzengAIB

I'm afraid I haven't implemented any mem cache check like that.

luisrecuenco avatar Sep 29 '14 17:09 luisrecuenco