public class Finalizer
extends java.lang.Object
| Constructor and Description |
|---|
Finalizer() |
| Modifier and Type | Method and Description |
|---|---|
static void |
addFinalizer(java.lang.Object o,
java.lang.Runnable r)
Schedules a Runnable to be run after garbage collection of the object.
|
static void |
clearFinalizers(java.lang.Object o)
Cancels any references scheduled to be run after garbage
collection of the argument 'o'.
|
public static void addFinalizer(java.lang.Object o,
java.lang.Runnable r)
o - The object to monitor for garbage collectionr - The routine to be executed after GC-ing the objectpublic static void clearFinalizers(java.lang.Object o)
o - Object to cancel references for