Search Options

Results per page
Sort
Preferred Languages
Advance

Results 61 - 70 of 158 for execute (0.21 sec)

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

      static class ExecutorSpy implements Executor {
    
        Executor delegate;
        boolean wasExecuted;
    
        public ExecutorSpy(Executor delegate) {
          this.delegate = delegate;
        }
    
        @Override
        public void execute(Runnable command) {
          delegate.execute(command);
          wasExecuted = true;
        }
      }
    
      public void testTransform_Executor() throws Exception {
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Tue Feb 20 17:00:05 GMT 2024
    - 144.5K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/util/concurrent/AbstractTransformFuture.java

          ListenableFuture<I> input,
          AsyncFunction<? super I, ? extends O> function,
          Executor executor) {
        checkNotNull(executor);
        AsyncTransformFuture<I, O> output = new AsyncTransformFuture<>(input, function);
        input.addListener(output, rejectionPropagatingExecutor(executor, output));
        return output;
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 01 21:46:34 GMT 2024
    - 10.6K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/util/concurrent/AbstractFuture.java

        @CheckForNull // null only for TOMBSTONE
        final Executor executor;
    
        // writes to next are made visible by subsequent CAS's on the listeners field
        @CheckForNull Listener next;
    
        Listener(Runnable task, Executor executor) {
          this.task = task;
          this.executor = executor;
        }
    
        Listener() {
          this.task = null;
          this.executor = null;
        }
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 22 21:17:24 GMT 2024
    - 63K bytes
    - Viewed (0)
  4. android/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
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Feb 13 14:28:25 GMT 2024
    - 7.3K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/util/concurrent/WrappingScheduledExecutorServiceTest.java

        }
    
        @Override
        public <T> Future<T> submit(Runnable task, T result) {
          throw new UnsupportedOperationException();
        }
    
        @Override
        public void execute(Runnable command) {
          throw new UnsupportedOperationException();
        }
      }
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Dec 16 19:54:45 GMT 2020
    - 7.6K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/util/concurrent/UninterruptiblesTest.java

        assertInterrupted();
      }
    
      // executor.awaitTermination Testcases
      public void testTryAwaitTerminationUninterruptiblyLongTimeUnit_success() {
        ExecutorService executor = newFixedThreadPool(1);
        requestInterruptIn(500);
        executor.execute(new SleepTask(1000));
        executor.shutdown();
        assertTrue(awaitTerminationUninterruptibly(executor, LONG_DELAY_MS, MILLISECONDS));
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Feb 09 22:57:07 GMT 2022
    - 30.9K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/util/concurrent/TrustedListenableFutureTask.java

        return new TrustedListenableFutureTask<>(callable);
      }
    
      /**
       * Creates a {@code ListenableFutureTask} that will upon running, execute the given {@code
       * Runnable}, and arrange that {@code get} will return the given result on successful completion.
       *
       * @param runnable the runnable task
    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)
  8. guava/src/com/google/common/collect/HashBiMap.java

       * equivalently, if this inverse view contains a key that is equal to {@code value}).
       *
       * <p>Due to the property that values in a BiMap are unique, this will tend to execute in
       * faster-than-linear time.
       *
       * @param value the object to search for in the values of this BiMap
       * @return true if a mapping exists from a key to the specified value
       */
      @Override
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Fri Oct 13 14:11:58 GMT 2023
    - 24.5K bytes
    - Viewed (0)
  9. guava-tests/benchmark/com/google/common/util/concurrent/ExecutionListBenchmark.java

          final Runnable runnable;
          final Executor executor;
    
          RunnableExecutorPair(Runnable runnable, Executor executor) {
            this.runnable = runnable;
            this.executor = executor;
          }
    
          void execute() {
            try {
              executor.execute(runnable);
            } catch (RuntimeException e) {
              log.log(
                  Level.SEVERE,
                  "RuntimeException while executing runnable "
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Apr 17 15:19:38 GMT 2023
    - 20.4K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/util/concurrent/AbstractIdleServiceTest.java

      }
    
      public void testTimeout() throws Exception {
        // Create a service whose executor will never run its commands
        Service service =
            new TestService() {
              @Override
              protected Executor executor() {
                return new Executor() {
                  @Override
                  public void execute(Runnable command) {}
                };
              }
    
              @Override
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 7.5K bytes
    - Viewed (0)
Back to top