Class GarbageCollectionNotifier
- java.lang.Object
-
- com.biomatters.geneious.publicapi.utilities.GarbageCollectionNotifier
-
public class GarbageCollectionNotifier extends java.lang.Object
Provides a system for notifying when an object has been garbage collected. Normally using finalize on an object is sufficient, except when you are dealing with objects you can't subclass. e.g. Strings.- Since:
- API 4.30 (Geneious 5.3.0)
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static void
add(java.lang.Object object, java.lang.Runnable runnable)
Sets things up so that soon after this object is garbage collected, the given Runnable is invoked.
-
-
-
Method Detail
-
add
public static void add(java.lang.Object object, java.lang.Runnable runnable)
Sets things up so that soon after this object is garbage collected, the given Runnable is invoked.- Parameters:
object
- the object to watch for garbage collectionrunnable
- the runnable to invoke soon after the object is garbage collected.
-
-