- Sort Score
- Result 10 results
- Languages All
Results 71 - 80 of 689 for executor (0.04 sec)
-
guava-tests/test/com/google/common/util/concurrent/TrustedListenableFutureTaskTest.java
} }; for (int j = 0; j < 10; j++) { executor.execute(wrapper); } barrier.await(); // release the threads! barrier.await(); // wait for them all to complete assertEquals(1, task.get().intValue()); assertEquals(1, counter.get()); } executor.shutdown(); } @J2ktIncompatible @GwtIncompatible // blocking wait
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 7.2K bytes - Viewed (0) -
samples/guide/src/main/java/okhttp3/recipes/kt/CancelCall.kt
* limitations under the License. */ package okhttp3.recipes.kt import java.io.IOException import java.util.concurrent.Executors import java.util.concurrent.TimeUnit import okhttp3.OkHttpClient import okhttp3.Request class CancelCall { private val executor = Executors.newScheduledThreadPool(1) private val client = OkHttpClient() fun run() { val request = Request .Builder()
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Wed Mar 19 19:25:20 UTC 2025 - 2K bytes - Viewed (0) -
android-test/src/test/kotlin/okhttp/android/test/ShadowDnsResolver.kt
val flags: Int, val callback: DnsResolver.Callback<List<InetAddress>>, ) @Implementation fun query( network: Network?, domain: String, nsType: Int, flags: Int, executor: Executor, cancellationSignal: CancellationSignal?, callback: DnsResolver.Callback<List<InetAddress>>, ) { responder(Request(network, domain, nsType, flags, callback)) } companion object {
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Mon Dec 30 23:28:56 UTC 2024 - 1.7K bytes - Viewed (0) -
samples/crawler/src/main/java/okhttp3/sample/Crawler.java
} private void parallelDrainQueue(int threadCount) { ExecutorService executor = Executors.newFixedThreadPool(threadCount); for (int i = 0; i < threadCount; i++) { executor.execute(() -> { try { drainQueue(); } catch (Throwable e) { e.printStackTrace(); } }); } executor.shutdown(); } private void drainQueue() throws Exception {
Registered: Fri Sep 05 11:42:10 UTC 2025 - Last Modified: Wed Jul 23 00:58:06 UTC 2025 - 5K bytes - Viewed (0) -
fess-crawler/src/test/java/org/codelibs/fess/crawler/transformer/impl/AbstractTransformerTest.java
final AtomicInteger errorCount = new AtomicInteger(0); testTransformer.setName("concurrentName"); ExecutorService executor = Executors.newFixedThreadPool(threadCount); for (int i = 0; i < threadCount; i++) { final int threadId = i; executor.submit(new Runnable() { @Override public void run() { try {
Registered: Sun Sep 21 03:50:09 UTC 2025 - Last Modified: Sat Sep 06 04:15:37 UTC 2025 - 20.8K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/FluentFutureTest.java
ScheduledExecutorService executor = newScheduledThreadPool(1); try { FluentFuture<?> f = FluentFuture.from(SettableFuture.create()).withTimeout(0, SECONDS, executor); ExecutionException e = assertThrows(ExecutionException.class, () -> f.get()); assertThat(e).hasCauseThat().isInstanceOf(TimeoutException.class); } finally { executor.shutdown(); } }
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Thu Aug 07 16:05:33 UTC 2025 - 5.8K bytes - Viewed (0) -
guava/src/com/google/common/util/concurrent/ForwardingListeningExecutorService.java
import java.util.concurrent.Callable; import org.jspecify.annotations.Nullable; /** * A listening executor service which forwards all its method calls to another listening executor * service. Subclasses should override one or more methods to modify the behavior of the backing * executor service as desired per the <a * href="http://en.wikipedia.org/wiki/Decorator_pattern">decorator pattern</a>. *
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Sun Dec 22 03:38:46 UTC 2024 - 2.2K bytes - Viewed (0) -
fess-crawler/src/main/java/org/codelibs/fess/crawler/client/http/form/FormScheme.java
} /** * Authenticates using the form scheme. * @param credentials The credentials. * @param executor The executor for HTTP requests. */ public void authenticate(final Credentials credentials, final BiConsumer<HttpUriRequest, BiConsumer<HttpResponse, HttpEntity>> executor) { final String tokenUrl = getParameter(TOKEN_URL); final String tokenPattern = getParameter(TOKEN_PATTERN);
Registered: Sun Sep 21 03:50:09 UTC 2025 - Last Modified: Sun Jul 06 02:13:03 UTC 2025 - 14.3K bytes - Viewed (1) -
src/test/java/jcifs/smb/NtlmPasswordAuthenticatorTimingAttackTest.java
final int operationsPerThread = 100; final ExecutorService executor = Executors.newFixedThreadPool(threadCount); final List<Long> timings = Collections.synchronizedList(new ArrayList<>()); try { for (int t = 0; t < threadCount; t++) { executor.submit(() -> { for (int i = 0; i < operationsPerThread; i++) {
Registered: Sun Sep 07 00:10:21 UTC 2025 - Last Modified: Sun Aug 31 08:00:57 UTC 2025 - 11.2K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/ForwardingListeningExecutorService.java
import java.util.concurrent.Callable; import org.jspecify.annotations.Nullable; /** * A listening executor service which forwards all its method calls to another listening executor * service. Subclasses should override one or more methods to modify the behavior of the backing * executor service as desired per the <a * href="http://en.wikipedia.org/wiki/Decorator_pattern">decorator pattern</a>. *
Registered: Fri Sep 05 12:43:10 UTC 2025 - Last Modified: Sun Dec 22 03:38:46 UTC 2024 - 2.2K bytes - Viewed (0)