- Sort Score
- Result 10 results
- Languages All
Results 1 - 10 of 908 for Callable (0.15 sec)
-
guava-tests/test/com/google/common/util/concurrent/CallablesTest.java
Callable<@Nullable Void> callable = new Callable<@Nullable Void>() { @Override public @Nullable Void call() throws Exception { assertEquals(Thread.currentThread().getName(), newName.get()); return null; } }; Callables.threadRenaming(callable, newName).call();
Java - Registered: Fri Apr 12 12:43:09 GMT 2024 - Last Modified: Tue Feb 13 14:28:25 GMT 2024 - 5.4K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/Callables.java
* @param nameSupplier The supplier of thread names, {@link Supplier#get get} will be called once * for each invocation of the wrapped callable. */ @J2ktIncompatible @GwtIncompatible // threads static <T extends @Nullable Object> Callable<T> threadRenaming( Callable<T> callable, Supplier<String> nameSupplier) { checkNotNull(nameSupplier); checkNotNull(callable); return () -> {
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Fri May 12 18:32:03 GMT 2023 - 4.4K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/SimpleTimeLimiter.java
} @ParametricNullness private <T extends @Nullable Object> T callWithTimeout( Callable<T> callable, long timeoutDuration, TimeUnit timeoutUnit, boolean amInterruptible) throws Exception { checkNotNull(callable); checkNotNull(timeoutUnit); checkPositiveTimeout(timeoutDuration); Future<T> future = executor.submit(callable); try { return amInterruptible
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Tue Jun 27 14:21:11 GMT 2023 - 9.7K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/TimeLimiter.java
* @throws ExecutionException if {@code callable} throws a checked exception * @throws UncheckedExecutionException if {@code callable} throws a {@code RuntimeException} * @throws ExecutionError if {@code callable} throws an {@code Error} * @since 22.0 */ @CanIgnoreReturnValue @ParametricNullness <T extends @Nullable Object> T callUninterruptiblyWithTimeout( Callable<T> callable, long timeoutDuration, TimeUnit timeoutUnit)
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Fri May 12 18:32:03 GMT 2023 - 8.3K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/FakeTimeLimiter.java
@Override @ParametricNullness public <T extends @Nullable Object> T callWithTimeout( Callable<T> callable, long timeoutDuration, TimeUnit timeoutUnit) throws ExecutionException { checkNotNull(callable); checkNotNull(timeoutUnit); try { return callable.call(); } catch (RuntimeException e) { throw new UncheckedExecutionException(e);
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Thu Dec 14 20:35:03 GMT 2023 - 3.5K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/TrustedListenableFutureTaskTest.java
final CountDownLatch exitLatch = new CountDownLatch(1); final TrustedListenableFutureTask<@Nullable Void> task = TrustedListenableFutureTask.create( new Callable<@Nullable Void>() { @Override public @Nullable Void call() throws Exception { enterLatch.countDown(); new CountDownLatch(1).await(); // wait forever
Java - Registered: Fri Apr 12 12:43:09 GMT 2024 - Last Modified: Tue Feb 13 14:28:25 GMT 2024 - 7.3K bytes - Viewed (0) -
android/guava-testlib/src/com/google/common/util/concurrent/testing/SameThreadScheduledExecutorService.java
return schedule(java.util.concurrent.Executors.callable(command), delay, unit); } @Override public <V> ListenableScheduledFuture<V> schedule( Callable<V> callable, long delay, TimeUnit unit) { Preconditions.checkNotNull(callable, "callable must not be null!"); Preconditions.checkNotNull(unit, "unit must not be null!"); ListenableFuture<V> delegateFuture = submit(callable);
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Wed Oct 06 00:47:57 GMT 2021 - 6.4K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/WrappingExecutorService.java
this.delegate = checkNotNull(delegate); } /** * Wraps a {@code Callable} for submission to the underlying executor. This method is also applied * to any {@code Runnable} passed to the default implementation of {@link #wrapTask(Runnable)}. */ protected abstract <T extends @Nullable Object> Callable<T> wrapTask(Callable<T> callable); /**
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Tue Apr 04 09:45:04 GMT 2023 - 5.5K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/TrustedListenableFutureTask.java
class TrustedListenableFutureTask<V extends @Nullable Object> extends FluentFuture.TrustedFuture<V> implements RunnableFuture<V> { static <V extends @Nullable Object> TrustedListenableFutureTask<V> create( AsyncCallable<V> callable) { return new TrustedListenableFutureTask<>(callable); } static <V extends @Nullable Object> TrustedListenableFutureTask<V> create(Callable<V> callable) {
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Fri Oct 01 17:18:04 GMT 2021 - 5.6K bytes - Viewed (0) -
android/guava-testlib/test/com/google/common/testing/FakeTickerTest.java
runConcurrentTest( numberOfThreads, new Callable<@Nullable Void>() { @Override public @Nullable Void call() throws Exception { long unused = ticker.read(); return null; } }); assertEquals(incrementByNanos * numberOfThreads, ticker.read()); } /** Runs {@code callable} concurrently {@code numberOfThreads} times. */
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Tue Feb 06 14:40:46 GMT 2024 - 6.4K bytes - Viewed (0)