IBM User Guide for Java V7 on Windows > IBM SDK for Java > The collector and the allocator > Global garbage collection
Reference objects
When a reference object is created, it is added to a list of reference objects of the same type. The referent is the object to which the reference object points.
Instances of SoftReference, WeakReference, and PhantomReference are created by the user and cannot be changed; they cannot be made to refer to objects other than the object that they referenced on creation.
If an object has a class that defines a finalize method, a pointer to that object is added to a list of objects that require finalization.
During garbage collection, immediately following the mark phase, these lists are processed in a specific order:
- Soft
- Weak
- Final
- Phantom
- Soft, weak, and phantom reference processing
The Garbage Collector (GC) determines if a reference object is a candidate for collection and, if so, performs a collection process that differs for each reference type. Soft references are collected if their referent is not marked and if #get() has not been called on the reference object for a number of garbage collection cycles. Weak and phantom references are always collected if their referent is not marked.
Parent: Global garbage collection
Error 404 - Not Found Error 404 - Not Found
The document you are looking for may have been removed or re-named. Please contact the web site owner for further assistance.