Home
last modified time | relevance | path

Searched refs:latch (Results 1 – 11 of 11) sorted by relevance

/libcore/luni/src/test/java/libcore/java/lang/ref/
DFinalizeTest.java100 CountDownLatch latch = new CountDownLatch(5); in testWatchdogDoesNotFailForObjectsThatAreNearTheDeadline() local
101 createSlowFinalizer( 1, latch); in testWatchdogDoesNotFailForObjectsThatAreNearTheDeadline()
102 createSlowFinalizer(1000, latch); in testWatchdogDoesNotFailForObjectsThatAreNearTheDeadline()
103 createSlowFinalizer(2000, latch); in testWatchdogDoesNotFailForObjectsThatAreNearTheDeadline()
104 createSlowFinalizer(4000, latch); in testWatchdogDoesNotFailForObjectsThatAreNearTheDeadline()
105 createSlowFinalizer(8000, latch); in testWatchdogDoesNotFailForObjectsThatAreNearTheDeadline()
107 latch.await(); in testWatchdogDoesNotFailForObjectsThatAreNearTheDeadline()
110 public void createSlowFinalizer(final long millis, final CountDownLatch latch) { in createSlowFinalizer() argument
115 latch.countDown(); in createSlowFinalizer()
/libcore/luni/src/test/java/libcore/java/security/
DMessageDigestTest.java252 final CountDownLatch latch = new CountDownLatch(THREAD_COUNT); in testMessageDigest_MultipleThreads_Misuse() local
261 latch.countDown(); in testMessageDigest_MultipleThreads_Misuse()
262 latch.await(); in testMessageDigest_MultipleThreads_Misuse()
DSignatureTest.java1626 final CountDownLatch latch = new CountDownLatch(THREAD_COUNT); in testSignature_MultipleThreads_Misuse() local
1634 latch.countDown(); in testSignature_MultipleThreads_Misuse()
1635 latch.await(); in testSignature_MultipleThreads_Misuse()
/libcore/luni/src/main/java/java/net/
DInetAddress.java725 final CountDownLatch latch = new CountDownLatch(sourceAddresses.size()); in isReachable() local
735 while (latch.getCount() > 0) { in isReachable()
736 latch.countDown(); in isReachable()
741 latch.countDown(); in isReachable()
746 latch.await(); in isReachable()
/libcore/jsr166-tests/src/test/java/jsr166/
DJSR166TestCase.java783 public Callable<String> latchAwaitingStringTask(final CountDownLatch latch) { in latchAwaitingStringTask() argument
787 latch.await(); in latchAwaitingStringTask()
793 public Runnable awaiter(final CountDownLatch latch) {
796 await(latch);
800 public void await(CountDownLatch latch) {
802 assertTrue(latch.await(LONG_DELAY_MS, MILLISECONDS));
DForkJoinPoolTest.java667 CountDownLatch latch = new CountDownLatch(1); in testInvokeAny4() local
670 l.add(latchAwaitingStringTask(latch)); in testInvokeAny4()
677 latch.countDown(); in testInvokeAny4()
847 CountDownLatch latch = new CountDownLatch(1); in testTimedInvokeAny3() local
850 l.add(latchAwaitingStringTask(latch)); in testTimedInvokeAny3()
857 latch.countDown(); in testTimedInvokeAny3()
DPhaserTest.java642 final CountDownLatch latch = new CountDownLatch(1);
647 latch.countDown();
649 await(latch);
653 await(latch);
655 latch.countDown();
DScheduledExecutorTest.java818 CountDownLatch latch = new CountDownLatch(1); in testInvokeAny3() local
821 l.add(latchAwaitingStringTask(latch)); in testInvokeAny3()
828 latch.countDown(); in testInvokeAny3()
995 CountDownLatch latch = new CountDownLatch(1); in testTimedInvokeAny3() local
998 l.add(latchAwaitingStringTask(latch)); in testTimedInvokeAny3()
1005 latch.countDown(); in testTimedInvokeAny3()
DScheduledExecutorSubclassTest.java867 CountDownLatch latch = new CountDownLatch(1); in testInvokeAny3() local
870 l.add(latchAwaitingStringTask(latch)); in testInvokeAny3()
877 latch.countDown(); in testInvokeAny3()
1044 CountDownLatch latch = new CountDownLatch(1); in testTimedInvokeAny3() local
1047 l.add(latchAwaitingStringTask(latch)); in testTimedInvokeAny3()
1054 latch.countDown(); in testTimedInvokeAny3()
DThreadPoolExecutorTest.java1478 final CountDownLatch latch = new CountDownLatch(1); in testInvokeAny3() local
1484 l.add(latchAwaitingStringTask(latch)); in testInvokeAny3()
1491 latch.countDown(); in testInvokeAny3()
1690 final CountDownLatch latch = new CountDownLatch(1); in testTimedInvokeAny3() local
1696 l.add(latchAwaitingStringTask(latch)); in testTimedInvokeAny3()
1703 latch.countDown(); in testTimedInvokeAny3()
DThreadPoolExecutorSubclassTest.java1336 CountDownLatch latch = new CountDownLatch(1); in testInvokeAny3() local
1339 l.add(latchAwaitingStringTask(latch)); in testInvokeAny3()
1346 latch.countDown(); in testInvokeAny3()
1513 CountDownLatch latch = new CountDownLatch(1); in testTimedInvokeAny3() local
1516 l.add(latchAwaitingStringTask(latch)); in testTimedInvokeAny3()
1523 latch.countDown(); in testTimedInvokeAny3()