Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1 - 10 of 37 for Cancellation (0.06 seconds)

  1. android/guava/src/com/google/common/util/concurrent/AbstractFuture.java

        // unmeasurable (comparing done AbstractFutures with immediateFuture)
        if (obj instanceof Cancellation) {
          Cancellation cancellation = (Cancellation) obj;
          Throwable cause = cancellation.cause;
          throw cancellationExceptionWithCause("Task was cancelled.", cause);
        } else if (obj instanceof Failure) {
          Failure failure = (Failure) obj;
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Sat Mar 07 14:39:00 GMT 2026
    - 43.6K bytes
    - Click Count (0)
  2. android/guava/src/com/google/common/util/concurrent/ExecutionSequencer.java

     *
     * <p>This class has limited support for cancellation and other "early completions":
     *
     * <ul>
     *   <li>While calls to {@code submit} and {@code submitAsync} return a {@code Future} that can be
     *       cancelled, cancellation never propagates to a task that has started to run -- neither to
     *       the callable itself nor to any {@code Future} returned by an {@code AsyncCallable}.
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Tue Sep 23 01:35:55 GMT 2025
    - 22.1K bytes
    - Click Count (0)
  3. android/guava-tests/test/com/google/common/util/concurrent/AbstractFutureCancellationCauseTest.java

    import java.util.concurrent.Future;
    import java.util.concurrent.TimeUnit;
    import junit.framework.TestCase;
    import org.jspecify.annotations.NullUnmarked;
    
    /** Tests for {@link AbstractFuture} with the cancellation cause system property set */
    @AndroidIncompatible // custom classloading
    
    @NullUnmarked
    @GwtIncompatible
    @J2ktIncompatible
    public class AbstractFutureCancellationCauseTest extends TestCase {
    
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Mon Mar 16 22:45:21 GMT 2026
    - 6.3K bytes
    - Click Count (0)
  4. guava-tests/test/com/google/common/util/concurrent/AbstractFutureCancellationCauseTest.java

    import java.util.concurrent.Future;
    import java.util.concurrent.TimeUnit;
    import junit.framework.TestCase;
    import org.jspecify.annotations.NullUnmarked;
    
    /** Tests for {@link AbstractFuture} with the cancellation cause system property set */
    @AndroidIncompatible // custom classloading
    
    @NullUnmarked
    @GwtIncompatible
    @J2ktIncompatible
    public class AbstractFutureCancellationCauseTest extends TestCase {
    
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Mon Mar 16 22:45:21 GMT 2026
    - 6.3K bytes
    - Click Count (0)
  5. guava-testlib/src/com/google/common/util/concurrent/testing/AbstractListenableFutureTest.java

      /**
       * Tests that a canceled future throws a cancellation exception.
       *
       * <p>This method checks the cancel, isCancelled, and isDone methods.
       */
      public void testCanceledFutureThrowsCancellation() throws Exception {
    
        assertFalse(future.isDone());
        assertFalse(future.isCancelled());
    
        CountDownLatch successLatch = new CountDownLatch(1);
    
        // Run cancellation in a separate thread as an extra thread-safety test.
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Fri Jul 11 18:52:30 GMT 2025
    - 6.1K bytes
    - Click Count (0)
  6. okhttp-coroutines/README.md

      }
    }
    ```
    
    This is implemented using `suspendCancellableCoroutine`
    but uses the standard Dispatcher in OkHttp. This means
    that by default Kotlin's Dispatchers are not used.
    
    Cancellation if implemented sensibly in both directions.
    Cancelling a coroutine scope, will cancel the call.
    Cancelling a call, will throw a CancellationException
    Created: Fri Apr 03 11:42:14 GMT 2026
    - Last Modified: Thu Nov 09 15:47:27 GMT 2023
    - 609 bytes
    - Click Count (0)
  7. android/guava/src/com/google/common/util/concurrent/AggregateFuture.java

         * All elements of `futures` are completed, or this future has already completed and read
         * `futures` into a local variable (in preparation for propagating cancellation to them). In
         * either case, no one needs to read `futures` for cancellation purposes later. (And
         * cancellation purposes are the main reason to access `futures`, as discussed in its docs.)
         */
        this.futures = null;
      }
    
      enum ReleaseResourcesReason {
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Sun Dec 22 03:38:46 GMT 2024
    - 16K bytes
    - Click Count (0)
  8. okhttp/src/commonJvmAndroid/kotlin/okhttp3/internal/concurrent/Task.kt

     * earliest one wins. This applies to both executions scheduled with [TaskRunner.Queue.schedule] and
     * those implied by the returned execution delay.
     *
     * Cancellation
     * ------------
     *
     * Tasks may be canceled while they are waiting to be executed, or while they are executing.
     *
     * Canceling a task that is waiting to execute prevents that upcoming execution. Canceling a task
    Created: Fri Apr 03 11:42:14 GMT 2026
    - Last Modified: Fri Dec 27 13:39:56 GMT 2024
    - 2.4K bytes
    - Click Count (0)
  9. okhttp/src/commonJvmAndroid/kotlin/okhttp3/Callback.kt

     * limitations under the License.
     */
    package okhttp3
    
    import okio.IOException
    
    interface Callback {
      /**
       * Called when the request could not be executed due to cancellation, a connectivity problem or
       * timeout. Because networks can fail during an exchange, it is possible that the remote server
       * accepted the request before the failure.
       */
      fun onFailure(
        call: Call,
    Created: Fri Apr 03 11:42:14 GMT 2026
    - Last Modified: Fri Dec 27 13:39:56 GMT 2024
    - 1.6K bytes
    - Click Count (0)
  10. android/guava-testlib/src/com/google/common/util/concurrent/testing/AbstractListenableFutureTest.java

      /**
       * Tests that a canceled future throws a cancellation exception.
       *
       * <p>This method checks the cancel, isCancelled, and isDone methods.
       */
      public void testCanceledFutureThrowsCancellation() throws Exception {
    
        assertFalse(future.isDone());
        assertFalse(future.isCancelled());
    
        CountDownLatch successLatch = new CountDownLatch(1);
    
        // Run cancellation in a separate thread as an extra thread-safety test.
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Fri Jul 11 18:52:30 GMT 2025
    - 6.1K bytes
    - Click Count (0)
Back to Top