/external/robolectric-shadows/robolectric/src/test/java/org/robolectric/android/util/concurrent/ |
D | RoboExecutorServiceTest.java | 21 private final RoboExecutorService executorService = new RoboExecutorService(); field in RoboExecutorServiceTest 38 executorService.execute(runnable); in execute_shouldRunStuffOnBackgroundThread() 48 Future<String> future = executorService.submit(runnable, "foo"); in submitRunnable_shouldRunStuffOnBackgroundThread() 62 Future<String> future = executorService.submit(new Callable<String>() { in submitCallable_shouldRunStuffOnBackgroundThread() 82 assertThat(executorService.isShutdown()).isFalse(); in byDefault_IsNotShutdown() 87 assertThat(executorService.isTerminated()).isFalse(); in byDefault_IsNotTerminated() 92 executorService.execute(runnable); in whenShutdownBeforeSubmittedTasksAreExecuted_TaskIsNotInTranscript() 94 executorService.shutdown(); in whenShutdownBeforeSubmittedTasksAreExecuted_TaskIsNotInTranscript() 102 executorService.execute(runnable); in whenShutdownNow_ReturnedListContainsOneRunnable() 104 List<Runnable> notExecutedRunnables = executorService.shutdownNow(); in whenShutdownNow_ReturnedListContainsOneRunnable() [all …]
|
/external/okhttp/repackaged/okhttp/src/main/java/com/android/okhttp/ |
D | Dispatcher.java | 43 private ExecutorService executorService; field in Dispatcher 54 public Dispatcher(ExecutorService executorService) { in Dispatcher() argument 55 this.executorService = executorService; in Dispatcher() 62 if (executorService == null) { in getExecutorService() 63 executorService = new ThreadPoolExecutor(0, Integer.MAX_VALUE, 60, TimeUnit.SECONDS, in getExecutorService() 66 return executorService; in getExecutorService()
|
/external/okhttp/okhttp/src/main/java/com/squareup/okhttp/ |
D | Dispatcher.java | 41 private ExecutorService executorService; field in Dispatcher 52 public Dispatcher(ExecutorService executorService) { in Dispatcher() argument 53 this.executorService = executorService; in Dispatcher() 60 if (executorService == null) { in getExecutorService() 61 executorService = new ThreadPoolExecutor(0, Integer.MAX_VALUE, 60, TimeUnit.SECONDS, in getExecutorService() 64 return executorService; in getExecutorService()
|
/external/grpc-grpc-java/core/src/jmh/java/io/grpc/internal/ |
D | SerializingExecutorBenchmark.java | 43 private ExecutorService executorService = Executors.newSingleThreadExecutor(); field in SerializingExecutorBenchmark 44 private Executor executor = new SerializingExecutor(executorService); 67 executorService.shutdownNow(); in tearDown() 68 if (!executorService.awaitTermination(1, TimeUnit.SECONDS)) { in tearDown()
|
/external/guava/guava-tests/test/com/google/common/util/concurrent/ |
D | JdkFutureAdaptersTest.java | 83 ExecutorService executorService = newCachedThreadPool( in testListenInPoolThreadUsesGivenExecutor() local 87 ExecutorSpy spy = new ExecutorSpy(executorService); in testListenInPoolThreadUsesGivenExecutor() 98 listenableFuture.addListener(singleCallListener, executorService); in testListenInPoolThreadUsesGivenExecutor() 111 ExecutorService executorService = new ThreadPoolExecutor( in testListenInPoolThreadCustomExecutorInterrupted() local 123 listenInPoolThread(abstractFuture, executorService); in testListenInPoolThreadCustomExecutorInterrupted() 138 executorService.shutdownNow(); in testListenInPoolThreadCustomExecutorInterrupted()
|
/external/mockito/src/test/java/org/mockitousage/serialization/ |
D | ParallelSerializationTest.java | 28 final ExecutorService executorService = Executors.newFixedThreadPool(threadingFactor); in single_mock_being_serialized_in_different_classloaders_by_multiple_threads() local 41 futures.add(executorService.submit(new Callable<Object>() { in single_mock_being_serialized_in_different_classloaders_by_multiple_threads() 52 executorService.submit(new Callable<Object>() { in single_mock_being_serialized_in_different_classloaders_by_multiple_threads()
|
/external/dagger2/compiler/src/it/producers-functional-tests/src/test/java/producerstest/badexecutor/ |
D | BadExecutorTest.java | 31 ListeningExecutorService executorService = MoreExecutors.newDirectExecutorService(); in setUpComponent() local 34 .executor(executorService) in setUpComponent() 37 executorService.shutdown(); in setUpComponent()
|
/external/apache-commons-compress/src/main/java/org/apache/commons/compress/archivers/zip/ |
D | ParallelScatterZipCreator.java | 109 public ParallelScatterZipCreator(final ExecutorService executorService) { in ParallelScatterZipCreator() argument 110 this(executorService, new DefaultBackingStoreSupplier()); in ParallelScatterZipCreator() 120 public ParallelScatterZipCreator(final ExecutorService executorService, in ParallelScatterZipCreator() argument 123 es = executorService; in ParallelScatterZipCreator()
|
/external/guava/guava-tests/benchmark/com/google/common/util/concurrent/ |
D | ExecutionListBenchmark.java | 153 private ExecutorService executorService; 167 executorService = new ThreadPoolExecutor(NUM_THREADS, 175 executorService.submit(new Runnable() { 183 executorService.shutdown(); 244 executorService.submit(addTask); 246 executorService.submit(executeTask); 265 executorService.submit(executeTask); 267 executorService.submit(addTask);
|
/external/guava/guava/src/com/google/common/util/concurrent/ |
D | AbstractScheduledService.java | 164 private volatile ScheduledExecutorService executorService; 191 executorService = MoreExecutors.renamingDecorator(executor(), new Supplier<String>() { 196 executorService.execute(new Runnable() { 201 runningTask = scheduler().schedule(delegate, executorService, task); 215 executorService.execute(new Runnable() {
|
D | MoreExecutors.java | 672 */ static <T> T invokeAnyImpl(ListeningExecutorService executorService, in invokeAnyImpl() argument 675 checkNotNull(executorService); in invokeAnyImpl() 694 futures.add(submitAndAddQueueListener(executorService, it.next(), futureQueue)); in invokeAnyImpl() 703 futures.add(submitAndAddQueueListener(executorService, it.next(), futureQueue)); in invokeAnyImpl() 746 ListeningExecutorService executorService, Callable<T> task, in submitAndAddQueueListener() argument 748 final ListenableFuture<T> future = executorService.submit(task); in submitAndAddQueueListener()
|
/external/desugar/test/java/com/google/devtools/build/android/desugar/runtime/ |
D | ConcurrentWeakIdentityHashMapTest.java | 145 ExecutorService executorService = Executors.newFixedThreadPool(workers.size()); in testFunctionalCorrectnessForMultiThreadedUse() local 146 workers.forEach(executorService::execute); in testFunctionalCorrectnessForMultiThreadedUse() 147 executorService.shutdown(); in testFunctionalCorrectnessForMultiThreadedUse() 148 executorService.awaitTermination(Long.MAX_VALUE, TimeUnit.DAYS); // wait for completion. in testFunctionalCorrectnessForMultiThreadedUse()
|
/external/guava/guava-testlib/test/com/google/common/testing/ |
D | FakeTickerTest.java | 150 ExecutorService executorService = Executors.newFixedThreadPool(numberOfThreads); in runConcurrentTest() local 154 executorService.submit(new Callable<Void>() { in runConcurrentTest()
|
/external/glide/third_party/disklrucache/src/main/java/com/bumptech/glide/disklrucache/ |
D | DiskLruCache.java | 158 final ThreadPoolExecutor executorService = field in DiskLruCache 430 executorService.submit(cleanupCallable); in get() 489 executorService.submit(cleanupCallable); in setMaxSize() 560 executorService.submit(cleanupCallable); in completeEdit() 605 executorService.submit(cleanupCallable); in remove()
|
/external/guice/extensions/servlet/test/com/google/inject/servlet/ |
D | ContinuingRequestIntegrationTest.java | 205 @Inject ExecutorService executorService; field in ContinuingRequestIntegrationTest.ContinuingServlet 220 executorService.submit(task); in doGet()
|
/external/mockito/src/test/java/org/mockitoutil/ |
D | ClassLoaders.java | 107 … ExecutorService executorService = Executors.newSingleThreadExecutor(new ThreadFactory() { in execute() local 116 Future<?> taskFuture = executorService.submit(new Runnable() { in execute() 130 executorService.shutdownNow(); in execute()
|
/external/robolectric-shadows/shadows/framework/src/main/java/org/robolectric/shadows/ |
D | ShadowSQLiteConnection.java | 460 …private static void shutdownDbExecutor(ExecutorService executorService, Collection<SQLiteConnectio… in shutdownDbExecutor() argument 462 getFuture("close connection on reset", executorService.submit(new Callable<Void>() { in shutdownDbExecutor() 471 executorService.shutdown(); in shutdownDbExecutor() 473 executorService.awaitTermination(30, TimeUnit.SECONDS); in shutdownDbExecutor()
|
/external/guice/core/test/com/google/inject/ |
D | InjectorTest.java | 426 final ExecutorService executorService = Executors.newSingleThreadExecutor(); 439 executorService.submit(
|