I\'m implementing an image cache system for caching downloaded image.
My strategy is based upon two-level cache: Memory-level and disk-level.
My class is very si
Don't do it! SoftReference is already enough! Actually SoftReference is designed to do exactly what you need. Sometimes SoftReference doesn't do what you need. Then you just get rid of SoftReference and write your own memory management logic. But as far as you use SoftReference you should not be worried about memory consumption, SoftReference does it for you.