Home
last modified time | relevance | path

Searched refs:executor (Results 1 – 25 of 48) sorted by relevance

12

/libcore/ojluni/src/main/java/java/util/concurrent/
DExecutorCompletionService.java107 private final Executor executor; field in ExecutorCompletionService
148 public ExecutorCompletionService(Executor executor) { in ExecutorCompletionService() argument
149 if (executor == null) in ExecutorCompletionService()
151 this.executor = executor; in ExecutorCompletionService()
152 this.aes = (executor instanceof AbstractExecutorService) ? in ExecutorCompletionService()
153 (AbstractExecutorService) executor : null; in ExecutorCompletionService()
170 public ExecutorCompletionService(Executor executor, in ExecutorCompletionService() argument
172 if (executor == null || completionQueue == null) in ExecutorCompletionService()
174 this.executor = executor; in ExecutorCompletionService()
175 this.aes = (executor instanceof AbstractExecutorService) ? in ExecutorCompletionService()
[all …]
DCompletionStage.java205 Executor executor); in thenApplyAsync() argument
250 Executor executor); in thenAcceptAsync() argument
291 Executor executor); in thenRunAsync() argument
352 Executor executor); in thenCombineAsync() argument
410 Executor executor); in thenAcceptBothAsync() argument
458 Executor executor); in runAfterBothAsync() argument
515 Executor executor); in applyToEitherAsync() argument
570 Executor executor); in acceptEitherAsync() argument
621 Executor executor); in runAfterEitherAsync() argument
699 Executor executor); in thenComposeAsync() argument
[all …]
DExecutors.java322 public static ExecutorService unconfigurableExecutorService(ExecutorService executor) { in unconfigurableExecutorService() argument
323 if (executor == null) in unconfigurableExecutorService()
325 return new DelegatedExecutorService(executor); in unconfigurableExecutorService()
338 …cheduledExecutorService unconfigurableScheduledExecutorService(ScheduledExecutorService executor) { in unconfigurableScheduledExecutorService() argument
339 if (executor == null) in unconfigurableScheduledExecutorService()
341 return new DelegatedScheduledExecutorService(executor); in unconfigurableScheduledExecutorService()
629 DelegatedExecutorService(ExecutorService executor) { e = executor; }
670 FinalizableDelegatedExecutorService(ExecutorService executor) {
671 super(executor);
686 DelegatedScheduledExecutorService(ScheduledExecutorService executor) {
[all …]
DCompletableFuture.java518 Executor executor; // executor to use (null if none) field in CompletableFuture.UniCompletion
522 UniCompletion(Executor executor, CompletableFuture<V> dep, in UniCompletion() argument
524 this.executor = executor; this.dep = dep; this.src = src; in UniCompletion()
534 Executor e = executor; in claim()
538 executor = null; // disable in claim()
579 UniApply(Executor executor, CompletableFuture<V> dep, in UniApply() argument
582 super(executor, dep, src); this.fn = fn; in UniApply()
635 UniAccept(Executor executor, CompletableFuture<Void> dep, in UniAccept() argument
637 super(executor, dep, src); this.fn = fn; in UniAccept()
690 UniRun(Executor executor, CompletableFuture<Void> dep, in UniRun() argument
[all …]
DRejectedExecutionHandler.java61 void rejectedExecution(Runnable r, ThreadPoolExecutor executor); in rejectedExecution() argument
/libcore/ojluni/src/main/java/sun/nio/ch/
DThreadPool.java43 private final ExecutorService executor; field in ThreadPool
52 private ThreadPool(ExecutorService executor, in ThreadPool() argument
56 this.executor = executor; in ThreadPool()
61 ExecutorService executor() { in executor() method in ThreadPool
62 return executor; in executor()
121 ExecutorService executor = Executors.newCachedThreadPool(threadFactory); in createDefault() local
122 return new ThreadPool(executor, false, initialSize); in createDefault()
129 ExecutorService executor = Executors.newFixedThreadPool(nThreads, factory); in create() local
130 return new ThreadPool(executor, true, nThreads); in create()
134 public static ThreadPool wrap(ExecutorService executor, int initialSize) { in wrap() argument
[all …]
DSimpleAsynchronousFileChannelImpl.java47 ThreadPool.createDefault().executor();
60 ExecutorService executor) in SimpleAsynchronousFileChannelImpl() argument
62 super(fdObj, reading, writing, executor); in SimpleAsynchronousFileChannelImpl()
71 ExecutorService executor = (pool == null) ? in open() local
72 DefaultExecutorHolder.defaultExecutor : pool.executor(); in open()
73 return new SimpleAsynchronousFileChannelImpl(fdo, reading, writing, executor); in open()
190 Invoker.invokeIndirectly(handler, attachment, null, exc, executor); in implLock()
231 executor.execute(task); in implLock()
305 Invoker.invokeIndirectly(handler, attachment, 0, exc, executor); in implRead()
339 executor.execute(task); in implRead()
[all …]
DAsynchronousChannelGroupImpl.java91 final ExecutorService executor() { in executor() method in AsynchronousChannelGroupImpl
92 return pool.executor(); in executor()
140 pool.executor().execute(task);
161 pool.executor().execute(bindToGroup(task));
188 pool.executor().execute(bindToGroup(task));
219 return pool.executor().isTerminated();
251 pool.executor().shutdown();
309 return pool.executor().awaitTermination(timeout, unit);
DAsynchronousFileChannelImpl.java55 protected final ExecutorService executor; field in AsynchronousFileChannelImpl
60 ExecutorService executor) in AsynchronousFileChannelImpl() argument
65 this.executor = executor; in AsynchronousFileChannelImpl()
68 final ExecutorService executor() { in executor() method in AsynchronousFileChannelImpl
69 return executor; in executor()
DLinuxAsynchronousChannelProvider.java61 …public AsynchronousChannelGroup openAsynchronousChannelGroup(ExecutorService executor, int initial… in openAsynchronousChannelGroup() argument
64 return new EPollPort(this, ThreadPool.wrap(executor, initialSize)).start(); in openAsynchronousChannelGroup()
/libcore/ojluni/src/main/java/java/nio/channels/
DAsynchronousChannelGroup.java228 public static AsynchronousChannelGroup withCachedThreadPool(ExecutorService executor, in withCachedThreadPool() argument
233 .openAsynchronousChannelGroup(executor, initialSize); in withCachedThreadPool()
269 public static AsynchronousChannelGroup withThreadPool(ExecutorService executor) in withThreadPool() argument
273 .openAsynchronousChannelGroup(executor, 0); in withThreadPool()
DAsynchronousFileChannel.java243 ExecutorService executor, in open() argument
248 return provider.newAsynchronousFileChannel(file, options, executor, attrs); in open()
/libcore/ojluni/annotations/mmodule/java/util/concurrent/
DCompletableFuture.annotated.java48 …(java.util.function.Supplier<U> supplier, java.util.concurrent.Executor executor) { throw new Runt… in supplyAsync() argument
52 …id> runAsync(java.lang.Runnable runnable, java.util.concurrent.Executor executor) { throw new Runt… in runAsync() argument
74 …ction.Function<? super T,? extends U> fn, java.util.concurrent.Executor executor) { throw new Runt… in thenApplyAsync() argument
80 …util.function.Consumer<? super T> action, java.util.concurrent.Executor executor) { throw new Runt… in thenAcceptAsync() argument
86 …> thenRunAsync(java.lang.Runnable action, java.util.concurrent.Executor executor) { throw new Runt… in thenRunAsync() argument
92 …tion<? super T,? super U,? extends V> fn, java.util.concurrent.Executor executor) { throw new Runt… in thenCombineAsync() argument
98 …n.BiConsumer<? super T,? super U> action, java.util.concurrent.Executor executor) { throw new Runt… in thenAcceptBothAsync() argument
104 …tage<?> other, java.lang.Runnable action, java.util.concurrent.Executor executor) { throw new Runt… in runAfterBothAsync() argument
110 …a.util.function.Function<? super T,U> fn, java.util.concurrent.Executor executor) { throw new Runt… in applyToEitherAsync() argument
116 …util.function.Consumer<? super T> action, java.util.concurrent.Executor executor) { throw new Runt… in acceptEitherAsync() argument
[all …]
/libcore/support/src/test/java/libcore/javax/net/ssl/
DTestSSLSocketPair.java78 ExecutorService executor = Executors.newFixedThreadPool(2); in connect() local
79 Future s = executor.submit(new Callable<Void>() { in connect()
88 Future c = executor.submit(new Callable<Void>() { in connect()
97 executor.shutdown(); in connect()
/libcore/luni/src/test/java/tests/security/
DSecureRandomTest.java79 ExecutorService executor = Executors.newFixedThreadPool(threads); in testSecureRandomThreadSafety() local
80 ExecutorCompletionService ecs = new ExecutorCompletionService(executor); in testSecureRandomThreadSafety()
91 executor.shutdown(); in testSecureRandomThreadSafety()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/io/
DOutputStreamTesterTest.java116 private ExecutorService executor; field in OutputStreamTesterTest.PipedOutputStreamSinkTester
123 executor = Executors.newSingleThreadExecutor(); in create()
124 future = executor.submit(new Callable<byte[]>() { in create()
141 executor.shutdown(); in getBytes()
DWriterTesterTest.java109 private ExecutorService executor; field in WriterTesterTest.PipedWriterCharSinkTester
116 executor = Executors.newSingleThreadExecutor(); in create()
117 future = executor.submit(new Callable<char[]>() { in create()
135 executor.shutdown(); in getChars()
/libcore/luni/src/test/java/libcore/java/lang/ref/
DReferenceQueueTest.java146 final ScheduledThreadPoolExecutor executor = new ScheduledThreadPoolExecutor(1); in runLater() local
147 executor.schedule(runnable, delayMillis, TimeUnit.MILLISECONDS); in runLater()
148 executor.shutdown(); in runLater()
/libcore/luni/src/test/java/libcore/java/util/zip/
DDeflaterOutputStreamTest.java76 ExecutorService executor = Executors.newSingleThreadExecutor(); in createInflaterStream() local
80 executor.submit(new Callable<Void>() { in createInflaterStream()
97 executor.shutdown(); in createInflaterStream()
/libcore/jsr166-tests/src/test/java/jsr166/
DSynchronousQueueTest.java481 final ExecutorService executor = Executors.newFixedThreadPool(2);
482 try (PoolCleaner cleaner = cleaner(executor)) {
484 executor.execute(new CheckedRunnable() {
492 executor.execute(new CheckedRunnable() {
508 final ExecutorService executor = Executors.newFixedThreadPool(2);
509 try (PoolCleaner cleaner = cleaner(executor)) {
510 executor.execute(new CheckedRunnable() {
518 executor.execute(new CheckedRunnable() {
DLinkedBlockingQueueTest.java731 final ExecutorService executor = Executors.newFixedThreadPool(2); in testOfferInExecutor() local
732 try (PoolCleaner cleaner = cleaner(executor)) { in testOfferInExecutor()
733 executor.execute(new CheckedRunnable() { in testOfferInExecutor()
741 executor.execute(new CheckedRunnable() { in testOfferInExecutor()
755 final ExecutorService executor = Executors.newFixedThreadPool(2); in testPollInExecutor() local
756 try (PoolCleaner cleaner = cleaner(executor)) { in testPollInExecutor()
757 executor.execute(new CheckedRunnable() { in testPollInExecutor()
765 executor.execute(new CheckedRunnable() { in testPollInExecutor()
/libcore/ojluni/src/test/java/util/concurrent/tck/
DSynchronousQueueTest.java501 final ExecutorService executor = Executors.newFixedThreadPool(2);
502 try (PoolCleaner cleaner = cleaner(executor)) {
504 executor.execute(new CheckedRunnable() {
512 executor.execute(new CheckedRunnable() {
528 final ExecutorService executor = Executors.newFixedThreadPool(2);
529 try (PoolCleaner cleaner = cleaner(executor)) {
530 executor.execute(new CheckedRunnable() {
538 executor.execute(new CheckedRunnable() {
/libcore/ojluni/annotations/hiddenapi/java/util/concurrent/
DExecutors.java102 java.util.concurrent.ExecutorService executor) { in unconfigurableExecutorService() argument
108 java.util.concurrent.ScheduledExecutorService executor) { in unconfigurableScheduledExecutorService() argument
189 DelegatedExecutorService(java.util.concurrent.ExecutorService executor) { in DelegatedExecutorService() argument
271 DelegatedScheduledExecutorService(java.util.concurrent.ScheduledExecutorService executor) { in DelegatedScheduledExecutorService() argument
315 FinalizableDelegatedExecutorService(java.util.concurrent.ExecutorService executor) { in FinalizableDelegatedExecutorService() argument
/libcore/luni/src/test/java/libcore/libcore/net/
DNetworkSecurityPolicyTest.java241 private final ExecutorService executor; field in NetworkSecurityPolicyTest.CapturingServerSocket
279 executor = Executors.newSingleThreadExecutor(); in CapturingServerSocket()
280 mFirstChunkReceivedFuture = executor.submit(callable); in CapturingServerSocket()
294 executor.shutdown(); in close()
/libcore/luni/src/test/java/libcore/java/nio/channels/
DServerSocketChannelTest.java168 ExecutorService executor = Executors.newSingleThreadExecutor(); in bind_loopback() local
184 Future<Integer> countFuture = executor.submit(new CountingServer(ssc, latch)); in bind_loopback()
206 executor.shutdown(); in bind_loopback()

12