- Sort Score
- Num 10 results
- Language All
Results 1 - 8 of 8 for AsyncCallable (0.16 seconds)
-
android/guava-tests/test/com/google/common/util/concurrent/CallablesTest.java
String expected = "MyCallableString"; Callable<String> callable = () -> expected; AsyncCallable<String> asyncCallable = Callables.asAsyncCallable(callable, newDirectExecutorService()); ListenableFuture<String> future = asyncCallable.call(); assertThat(future.get()).isEqualTo(expected); } @J2ktIncompatible @GwtIncompatible
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Mar 16 22:45:21 GMT 2026 - 4K bytes - Click Count (0) -
guava-tests/test/com/google/common/util/concurrent/CallablesTest.java
String expected = "MyCallableString"; Callable<String> callable = () -> expected; AsyncCallable<String> asyncCallable = Callables.asAsyncCallable(callable, newDirectExecutorService()); ListenableFuture<String> future = asyncCallable.call(); assertThat(future.get()).isEqualTo(expected); } @J2ktIncompatible @GwtIncompatible
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Mar 16 22:45:21 GMT 2026 - 4K bytes - Click Count (0) -
android/guava-tests/test/com/google/common/util/concurrent/FuturesTest.java
@SuppressWarnings("AnonymousToLambda") // We want an instance that can be GCed. AsyncCallable<Long> combiner = new AsyncCallable<Long>() { @Override public ListenableFuture<Long> call() { return SettableFuture.create(); } }; WeakReference<AsyncCallable<Long>> combinerRef = new WeakReference<>(combiner); ListenableFuture<Long> unused =Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Mar 16 22:45:21 GMT 2026 - 134K bytes - Click Count (0) -
guava-tests/test/com/google/common/util/concurrent/FuturesTest.java
@SuppressWarnings("AnonymousToLambda") // We want an instance that can be GCed. AsyncCallable<Long> combiner = new AsyncCallable<Long>() { @Override public ListenableFuture<Long> call() { return SettableFuture.create(); } }; WeakReference<AsyncCallable<Long>> combinerRef = new WeakReference<>(combiner); ListenableFuture<Long> unused =Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Mar 16 22:45:21 GMT 2026 - 134K bytes - Click Count (0) -
android/guava/src/com/google/common/util/concurrent/Futures.java
* * @throws RejectedExecutionException if the task cannot be scheduled for execution * @since 23.0 */ public static <O extends @Nullable Object> ListenableFuture<O> submitAsync( AsyncCallable<O> callable, Executor executor) { TrustedListenableFutureTask<O> task = TrustedListenableFutureTask.create(callable); executor.execute(task); return task; } /**
Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Tue Mar 17 19:26:39 GMT 2026 - 64.2K bytes - Click Count (0) -
guava-tests/test/com/google/common/util/concurrent/ExecutionSequencerTest.java
} void stop() { stopLatch.countDown(); } boolean isRunning() { return running; } } private static final class TestCallable implements AsyncCallable<@Nullable Void> { private final ListenableFuture<@Nullable Void> future; private boolean called = false; private TestCallable(ListenableFuture<@Nullable Void> future) { this.future = future;Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Mar 16 22:45:21 GMT 2026 - 13.6K bytes - Click Count (0) -
android/guava-tests/test/com/google/common/util/concurrent/ExecutionSequencerTest.java
} void stop() { stopLatch.countDown(); } boolean isRunning() { return running; } } private static final class TestCallable implements AsyncCallable<@Nullable Void> { private final ListenableFuture<@Nullable Void> future; private boolean called = false; private TestCallable(ListenableFuture<@Nullable Void> future) { this.future = future;Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Mon Mar 16 22:45:21 GMT 2026 - 13.6K bytes - Click Count (0) -
android/guava/src/com/google/common/util/concurrent/ClosingFuture.java
*/ public final <V extends @Nullable Object> ClosingFuture<V> callAsync( AsyncCombiningCallable<V> combiningCallable, Executor executor) { AsyncCallable<V> asyncCallable = new AsyncCallable<V>() { @Override public ListenableFuture<V> call() throws Exception { return new Peeker(inputs).callAsync(combiningCallable, closeables); }Created: Fri Apr 03 12:43:13 GMT 2026 - Last Modified: Wed Apr 01 17:27:13 GMT 2026 - 101.7K bytes - Click Count (0)