Skip navigation links
, but available in Java 8.
Cleaners serve the same purpose as finalize() methods, with 2 subtle differences: finalize() methods are better when resource disposal is non-trivial and/or slow The JVM does a better job of running Cleaners promptly
Checks whether caller modules have the access they expect to packages in other modules.
Utilities that should only be used as a last resort -- because, for example, they rely on reflective access to implementation details.