Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 12 for interruptTask (0.26 sec)

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

      /**
       * Any interruption that happens as a result of calling interruptTask will arrive before this
       * method is called. Complete Futures here.
       */
      abstract void afterRanInterruptiblySuccess(@ParametricNullness T result);
    
      /**
       * Any interruption that happens as a result of calling interruptTask will arrive before this
       * method is called. Complete Futures here.
       */
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri Sep 29 21:34:48 GMT 2023
    - 9.9K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/util/concurrent/InterruptibleTaskTest.java

            };
        Thread runner = new Thread(task);
        runner.start();
        isInterruptibleRegistered.await();
        RuntimeException expected = assertThrows(RuntimeException.class, () -> task.interruptTask());
        assertThat(expected)
            .hasMessageThat()
            .isEqualTo("I bet you didn't think Thread.interrupt could throw");
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 6.6K bytes
    - Viewed (0)
  3. guava-gwt/src-super/com/google/common/util/concurrent/super/com/google/common/util/concurrent/InterruptibleTask.java

      abstract T runInterruptibly() throws Exception;
    
      abstract void afterRanInterruptiblySuccess(T result);
    
      abstract void afterRanInterruptiblyFailure(Throwable error);
    
      final void interruptTask() {}
    
      abstract String toPendingString();
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Dec 08 20:30:27 GMT 2022
    - 1.6K bytes
    - Viewed (0)
  4. guava-gwt/src-super/com/google/common/util/concurrent/super/com/google/common/util/concurrent/AbstractFuture.java

          // TODO(lukes): consider adding the StackOverflowError protection from the server version
          delegate.cancel(mayInterruptIfRunning);
        }
    
        return true;
      }
    
      protected void interruptTask() {}
    
      @Override
      public boolean isCancelled() {
        return state.isCancelled();
      }
    
      @Override
      public boolean isDone() {
        return state.isDone();
      }
    
      /*
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Jan 22 19:37:41 GMT 2024
    - 12.3K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/util/concurrent/InterruptibleTaskTest.java

            };
        Thread runner = new Thread(task);
        runner.start();
        isInterruptibleRegistered.await();
        RuntimeException expected = assertThrows(RuntimeException.class, () -> task.interruptTask());
        assertThat(expected)
            .hasMessageThat()
            .isEqualTo("I bet you didn't think Thread.interrupt could throw");
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 6.6K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/util/concurrent/CombinedFuture.java

         */
        if (reason == OUTPUT_FUTURE_DONE) {
          this.task = null;
        }
      }
    
      @Override
      protected void interruptTask() {
        CombinedFutureInterruptibleTask<?> localTask = task;
        if (localTask != null) {
          localTask.interruptTask();
        }
      }
    
      @WeakOuter
      private abstract class CombinedFutureInterruptibleTask<T extends @Nullable Object>
          extends InterruptibleTask<T> {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 01 21:46:34 GMT 2024
    - 6.8K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/util/concurrent/AbstractFuture.java

          future.releaseWaiters();
          /*
           * We call interruptTask() immediately before afterDone() so that migrating between the two
           * can be a no-op.
           */
          if (callInterruptTask) {
            future.interruptTask();
            /*
             * Interruption doesn't propagate through a SetFuture chain (see getFutureValue), so don't
             * invoke interruptTask on any subsequent futures.
             */
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 22 21:17:24 GMT 2024
    - 63K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/util/concurrent/TrustedListenableFutureTask.java

      }
    
      @Override
      protected void afterDone() {
        super.afterDone();
    
        if (wasInterrupted()) {
          InterruptibleTask<?> localTask = task;
          if (localTask != null) {
            localTask.interruptTask();
          }
        }
    
        this.task = null;
      }
    
      @Override
      @CheckForNull
      protected String pendingToString() {
        InterruptibleTask<?> localTask = task;
        if (localTask != null) {
    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)
  9. guava-tests/test/com/google/common/util/concurrent/AbstractFutureBenchmarks.java

        public boolean cancel(boolean mayInterruptIfRunning) {
          if (!sync.cancel(mayInterruptIfRunning)) {
            return false;
          }
          executionList.execute();
          if (mayInterruptIfRunning) {
            interruptTask();
          }
          return true;
        }
    
        /**
         * Subclasses can override this method to implement interruption of the future's computation.
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed May 09 15:17:25 GMT 2018
    - 13.6K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/util/concurrent/AbstractFutureBenchmarks.java

        public boolean cancel(boolean mayInterruptIfRunning) {
          if (!sync.cancel(mayInterruptIfRunning)) {
            return false;
          }
          executionList.execute();
          if (mayInterruptIfRunning) {
            interruptTask();
          }
          return true;
        }
    
        /**
         * Subclasses can override this method to implement interruption of the future's computation.
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Apr 06 12:56:11 GMT 2023
    - 13.6K bytes
    - Viewed (0)
Back to top