Описание тега soft-references
A Soft Reference is a reference that does not protect the referenced object from collection by a garbage collector. An object referenced only by soft references is considered unreachable (or "weakly reachable") and so may be collected at any time.
The main difference between Soft and Weak references is that while both will allow the object to be reclaimed Soft references say "try to hang onto this unless we need the memory" whereas Weak references says "throw this away whenever you like". An object which is only weakly reachable (the strongest references to it are WeakReferences) will usually be discarded at the next garbage collection cycle, whereas objects with a SoftReference may be discarded, but will usually be kept.
A soft reference can be used to create new strong references, which then means that until those strong references go out of scope the object will no longer be eligible for garbage collection.
Soft references are used in areas such as caching, where you want to keep a reference to an object for re-use but allow the system to reclaim it if memory grows low.
Some garbage-collected languages feature or support various levels of weak references, such as Java, C#, Python, Perl and Lisp. Java also offers Weak References and Phantom References which offer variations on the same functionality.