Home
last modified time | relevance | path

Searched refs:futures (Results 1 – 8 of 8) sorted by relevance

/libcore/luni/src/main/java/java/util/concurrent/
DAbstractExecutorService.java118 ArrayList<Future<T>> futures = new ArrayList<Future<T>>(ntasks); in doInvokeAny() local
136 futures.add(ecs.submit(it.next())); in doInvokeAny()
145 futures.add(ecs.submit(it.next())); in doInvokeAny()
176 for (int i = 0, size = futures.size(); i < size; i++) in doInvokeAny()
177 futures.get(i).cancel(true); in doInvokeAny()
201 ArrayList<Future<T>> futures = new ArrayList<Future<T>>(tasks.size()); in invokeAll() local
206 futures.add(f); in invokeAll()
209 for (int i = 0, size = futures.size(); i < size; i++) { in invokeAll()
210 Future<T> f = futures.get(i); in invokeAll()
220 return futures; in invokeAll()
[all …]
DForkJoinPool.java2587 ArrayList<Future<T>> futures = new ArrayList<Future<T>>(tasks.size()); in invokeAll() local
2593 futures.add(f); in invokeAll()
2596 for (int i = 0, size = futures.size(); i < size; i++) in invokeAll()
2597 ((ForkJoinTask<?>)futures.get(i)).quietlyJoin(); in invokeAll()
2599 return futures; in invokeAll()
2602 for (int i = 0, size = futures.size(); i < size; i++) in invokeAll()
2603 futures.get(i).cancel(false); in invokeAll()
/libcore/jsr166-tests/src/test/java/jsr166/
DAbstractExecutorServiceTest.java354 List<Future<String>> futures = e.invokeAll(l); in testInvokeAll4() local
355 assertEquals(1, futures.size()); in testInvokeAll4()
357 futures.get(0).get(); in testInvokeAll4()
376 List<Future<String>> futures = e.invokeAll(l); in testInvokeAll5() local
377 assertEquals(2, futures.size()); in testInvokeAll5()
378 for (Future<String> future : futures) in testInvokeAll5()
548 List<Future<String>> futures = in testTimedInvokeAll4() local
550 assertEquals(1, futures.size()); in testTimedInvokeAll4()
552 futures.get(0).get(); in testTimedInvokeAll4()
571 List<Future<String>> futures = in testTimedInvokeAll5() local
[all …]
DScheduledExecutorTest.java917 List<Future<String>> futures = e.invokeAll(l); in testInvokeAll4() local
918 assertEquals(1, futures.size()); in testInvokeAll4()
920 futures.get(0).get(); in testInvokeAll4()
938 List<Future<String>> futures = e.invokeAll(l); in testInvokeAll5() local
939 assertEquals(2, futures.size()); in testInvokeAll5()
940 for (Future<String> future : futures) in testInvokeAll5()
1110 List<Future<String>> futures = in testTimedInvokeAll4() local
1112 assertEquals(1, futures.size()); in testTimedInvokeAll4()
1114 futures.get(0).get(); in testTimedInvokeAll4()
1132 List<Future<String>> futures = in testTimedInvokeAll5() local
[all …]
DScheduledExecutorSubclassTest.java966 List<Future<String>> futures = e.invokeAll(l); in testInvokeAll4() local
967 assertEquals(1, futures.size()); in testInvokeAll4()
969 futures.get(0).get(); in testInvokeAll4()
987 List<Future<String>> futures = e.invokeAll(l); in testInvokeAll5() local
988 assertEquals(2, futures.size()); in testInvokeAll5()
989 for (Future<String> future : futures) in testInvokeAll5()
1159 List<Future<String>> futures = in testTimedInvokeAll4() local
1161 assertEquals(1, futures.size()); in testTimedInvokeAll4()
1163 futures.get(0).get(); in testTimedInvokeAll4()
1181 List<Future<String>> futures = in testTimedInvokeAll5() local
[all …]
DForkJoinPoolTest.java768 List<Future<String>> futures = e.invokeAll(l); in testInvokeAll4() local
769 assertEquals(1, futures.size()); in testInvokeAll4()
771 futures.get(0).get(); in testInvokeAll4()
789 List<Future<String>> futures = e.invokeAll(l); in testInvokeAll5() local
790 assertEquals(2, futures.size()); in testInvokeAll5()
791 for (Future<String> future : futures) in testInvokeAll5()
964 List<Future<String>> futures in testTimedInvokeAll4() local
966 assertEquals(1, futures.size()); in testTimedInvokeAll4()
968 futures.get(0).get(); in testTimedInvokeAll4()
986 List<Future<String>> futures in testTimedInvokeAll5() local
[all …]
DThreadPoolExecutorTest.java1599 List<Future<String>> futures = e.invokeAll(l); in testInvokeAll4() local
1600 assertEquals(1, futures.size()); in testInvokeAll4()
1602 futures.get(0).get(); in testInvokeAll4()
1624 List<Future<String>> futures = e.invokeAll(l); in testInvokeAll5() local
1625 assertEquals(2, futures.size()); in testInvokeAll5()
1626 for (Future<String> future : futures) in testInvokeAll5()
1829 List<Future<String>> futures = in testTimedInvokeAll4() local
1831 assertEquals(1, futures.size()); in testTimedInvokeAll4()
1833 futures.get(0).get(); in testTimedInvokeAll4()
1854 List<Future<String>> futures = in testTimedInvokeAll5() local
[all …]
DThreadPoolExecutorSubclassTest.java1435 List<Future<String>> futures = e.invokeAll(l); in testInvokeAll4() local
1436 assertEquals(1, futures.size()); in testInvokeAll4()
1438 futures.get(0).get(); in testInvokeAll4()
1456 List<Future<String>> futures = e.invokeAll(l); in testInvokeAll5() local
1457 assertEquals(2, futures.size()); in testInvokeAll5()
1458 for (Future<String> future : futures) in testInvokeAll5()
1628 List<Future<String>> futures = in testTimedInvokeAll4() local
1630 assertEquals(1, futures.size()); in testTimedInvokeAll4()
1632 futures.get(0).get(); in testTimedInvokeAll4()
1650 List<Future<String>> futures = in testTimedInvokeAll5() local
[all …]