- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for Finalize (0.17 sec)
-
guava-testlib/test/com/google/common/testing/GcFinalizationTest.java
public void testAwait_CountDownLatch() { final CountDownLatch latch = new CountDownLatch(1); Object x = new Object() { @Override protected void finalize() { latch.countDown(); } }; x = null; // Hint to the JIT that x is unreachable GcFinalization.await(latch); assertEquals(0, latch.getCount()); }
Java - Registered: Fri Apr 19 12:43:09 GMT 2024 - Last Modified: Wed Sep 06 17:04:31 GMT 2023 - 7.4K bytes - Viewed (0) -
android/guava-testlib/test/com/google/common/testing/GcFinalizationTest.java
public void testAwait_CountDownLatch() { final CountDownLatch latch = new CountDownLatch(1); Object x = new Object() { @Override protected void finalize() { latch.countDown(); } }; x = null; // Hint to the JIT that x is unreachable GcFinalization.await(latch); assertEquals(0, latch.getCount()); }
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Wed Sep 06 17:04:31 GMT 2023 - 7.4K bytes - Viewed (0)