Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 90 for tank (0.15 sec)

  1. android/guava-tests/test/com/google/common/util/concurrent/ListenableFutureTaskTest.java

        assertFalse(task.isDone());
        assertFalse(task.isCancelled());
    
        // Start the task to put it in the RUNNING state.  Have to use a separate
        // thread because the task will block on the task latch after unblocking
        // the run latch.
        exec.execute(task);
        runLatch.await();
        assertEquals(1, listenerLatch.getCount());
        assertFalse(task.isDone());
        assertFalse(task.isCancelled());
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 4.7K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/util/concurrent/ExecutionSequencer.java

           *   user task -- which means that we already got past this code (or else we exited early
           *   above))
           */
          // Unconditionally set; there is no risk of throwing away a queued task from another thread,
          // because in order for the current task to run on this executor the previous task must have
          // already started execution. Because each task on a TaskNonReentrantExecutor can only produce
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 01 21:46:34 GMT 2024
    - 22.1K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/util/concurrent/AbstractScheduledService.java

                AbstractService service, ScheduledExecutorService executor, Runnable task) {
              return new FutureAsCancellable(
                  executor.scheduleWithFixedDelay(task, initialDelay, delay, unit));
            }
          };
        }
    
        /**
         * Returns a {@link Scheduler} that schedules the task using the {@link
         * ScheduledExecutorService#scheduleAtFixedRate} method.
         *
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Dec 13 19:45:20 GMT 2023
    - 25.8K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/util/concurrent/TrustedListenableFutureTask.java

      @CheckForNull private volatile InterruptibleTask<?> task;
    
      TrustedListenableFutureTask(Callable<V> callable) {
        this.task = new TrustedFutureInterruptibleTask(callable);
      }
    
      TrustedListenableFutureTask(AsyncCallable<V> callable) {
        this.task = new TrustedFutureInterruptibleAsyncTask(callable);
      }
    
      @Override
      public void run() {
        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)
  5. android/guava-tests/test/com/google/common/util/concurrent/InterruptibleTaskTest.java

    public final class InterruptibleTaskTest extends TestCase {
    
      // Regression test for a deadlock where a task could be stuck busy waiting for the task to
      // transition to DONE
      public void testInterruptThrows() throws Exception {
        final CountDownLatch isInterruptibleRegistered = new CountDownLatch(1);
        InterruptibleTask<@Nullable Void> task =
            new InterruptibleTask<@Nullable Void>() {
              @Override
    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)
  6. android/guava/src/com/google/common/util/concurrent/ForwardingExecutorService.java

      public <T extends @Nullable Object> Future<T> submit(Callable<T> task) {
        return delegate().submit(task);
      }
    
      @Override
      public Future<?> submit(Runnable task) {
        return delegate().submit(task);
      }
    
      @Override
      public <T extends @Nullable Object> Future<T> submit(
          Runnable task, @ParametricNullness T result) {
        return delegate().submit(task, result);
      }
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Apr 04 09:45:04 GMT 2023
    - 4.1K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/util/concurrent/Callables.java

       * running with have the given name.
       *
       * @param task The Runnable to wrap
       * @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 Runnable threadRenaming(Runnable task, Supplier<String> nameSupplier) {
        checkNotNull(nameSupplier);
    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)
  8. guava-testlib/src/com/google/common/util/concurrent/testing/TestingExecutors.java

       * MoreExecutors#newDirectExecutorService} and subject to the same constraints.
       *
       * <p>Although all tasks are immediately executed in the thread that submitted the task, this
       * {@code ExecutorService} imposes a small locking overhead on each task submission in order to
       * implement shutdown and termination behavior.
       *
       * <p>Because of the nature of single-thread execution, the methods {@code scheduleAtFixedRate}
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Fri May 26 22:04:00 GMT 2023
    - 6.7K bytes
    - Viewed (0)
  9. android/guava/src/com/google/common/util/concurrent/Futures.java

       *
       * @throws RejectedExecutionException if the task cannot be scheduled for execution
       * @since 28.2
       */
      public static <O extends @Nullable Object> ListenableFuture<O> submit(
          Callable<O> callable, Executor executor) {
        TrustedListenableFutureTask<O> task = TrustedListenableFutureTask.create(callable);
        executor.execute(task);
        return task;
      }
    
      /**
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 59.6K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/cache/CacheLoaderTest.java

      private static class QueuingExecutor implements Executor {
        private final Deque<Runnable> tasks = Queues.newArrayDeque();
    
        @Override
        public void execute(Runnable task) {
          tasks.add(task);
        }
    
        private void runNext() {
          tasks.removeFirst().run();
        }
      }
    
      public void testAsyncReload() throws Exception {
        final AtomicInteger loadCount = new AtomicInteger();
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Fri Aug 05 17:21:46 GMT 2022
    - 3.6K bytes
    - Viewed (0)
Back to top