Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 65 for Stacks (0.2 sec)

  1. guava-testlib/src/com/google/common/testing/CollectorTester.java

            }
            return pop(stack);
          }
    
          <E extends @Nullable Object> void push(List<E> stack, E value) {
            stack.add(value);
          }
    
          <E extends @Nullable Object> E pop(List<E> stack) {
            return stack.remove(stack.size() - 1);
          }
        };
    
        abstract <T extends @Nullable Object, A extends @Nullable Object, R extends @Nullable Object>
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Thu Feb 22 17:40:56 UTC 2024
    - 6.5K bytes
    - Viewed (0)
  2. android/guava-testlib/src/com/google/common/collect/testing/AbstractIteratorTester.java

        // TODO: verify contents afterward
        // TODO: something shiny and new instead of Stack
        // TODO: test whether null is supported (create a Feature)
        /**
         * The elements to be returned by future calls to {@code next()}, with the first at the top of
         * the stack.
         */
        final Stack<E> nextElements = new Stack<>();
    
        /**
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Tue Jun 11 16:13:05 UTC 2024
    - 20.7K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/util/concurrent/SequentialExecutorTest.java

      private static class FakeExecutor implements Executor {
        Queue<Runnable> tasks = Queues.newArrayDeque();
    
        @Override
        public void execute(Runnable command) {
          tasks.add(command);
        }
    
        boolean hasNext() {
          return !tasks.isEmpty();
        }
    
        void runNext() {
          assertTrue("expected at least one task to run", hasNext());
          tasks.remove().run();
        }
    
        void runAll() {
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Sep 06 17:04:31 UTC 2023
    - 11.4K bytes
    - Viewed (0)
  4. guava/src/com/google/common/util/concurrent/AbstractTransformFuture.java

         * setException(stackOverflowError) would fail:
         *
         * - If the stack overflowed before set()/setValue() could even store the result in the output
         * Future, then a call setException() would likely also overflow.
         *
         * - If the stack overflowed after set()/setValue() stored its result, then a call to
         * setException() will be a no-op because the Future is already done.
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Thu Feb 01 21:46:34 UTC 2024
    - 10.6K bytes
    - Viewed (0)
  5. android/guava/src/com/google/common/util/concurrent/MoreExecutors.java

       *       note about locking below.)
       *   <li>If many tasks will be triggered by the same event, one heavyweight task may delay other
       *       tasks -- even tasks that are not themselves {@code directExecutor} tasks.
       *   <li>If many such tasks are chained together (such as with {@code
       *       future.transform(...).transform(...).transform(...)....}), they may overflow the stack.
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed May 15 10:40:05 UTC 2024
    - 39K bytes
    - Viewed (0)
  6. android/guava-testlib/src/com/google/common/testing/GcFinalization.java

     *
     * <pre>{@code
     * // Helper function keeps victim stack-unreachable.
     * private WeakReference<Foo> fooWeakRef() {
     *   Foo x = ....;
     *   WeakReference<Foo> weakRef = new WeakReference<>(x);
     *   // ... use x ...
     *   x = null;  // Hint to the JIT that x is stack-unreachable
     *   return weakRef;
     * }
     * public void testFooLeak() {
     *   GcFinalization.awaitClear(fooWeakRef());
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Thu Feb 22 17:40:56 UTC 2024
    - 11.6K bytes
    - Viewed (0)
  7. guava/src/com/google/common/hash/Hashing.java

       *   <li>When you reduce the number of buckets, you can accept that the most recently added
       *       buckets will be removed first. More concretely, if you are dividing traffic among tasks,
       *       you can decrease the number of tasks from 15 and 10, killing off the final 5 tasks, and
       *       {@code consistentHash} will handle it. If, however, you are dividing traffic among
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Tue Apr 09 00:37:15 UTC 2024
    - 32.3K bytes
    - Viewed (0)
  8. android/guava-tests/test/com/google/common/util/concurrent/AbstractFutureCancellationCauseTest.java

        // cause system property.  This allows us to run with both settings of the property in one jvm
        // without resorting to even crazier hacks to reset static final boolean fields.
        System.setProperty("guava.concurrent.generate_cancellation_cause", "true");
        final String concurrentPackage = SettableFuture.class.getPackage().getName();
        classReloader =
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Sep 06 17:04:31 UTC 2023
    - 6.1K bytes
    - Viewed (0)
  9. guava-tests/test/com/google/common/util/concurrent/AbstractFutureCancellationCauseTest.java

        // cause system property.  This allows us to run with both settings of the property in one jvm
        // without resorting to even crazier hacks to reset static final boolean fields.
        System.setProperty("guava.concurrent.generate_cancellation_cause", "true");
        final String concurrentPackage = SettableFuture.class.getPackage().getName();
        classReloader =
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Sep 06 17:04:31 UTC 2023
    - 6.1K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/util/concurrent/MoreExecutorsTest.java

      public <T> void testListeningExecutorServiceInvokeAllJavadocCodeCompiles() throws Exception {
        ListeningExecutorService executor = newDirectExecutorService();
        List<Callable<T>> tasks = ImmutableList.of();
        List<? extends Future<?>> unused = executor.invokeAll(tasks);
      }
    
      public void testListeningDecorator() throws Exception {
        ListeningExecutorService service = listeningDecorator(newDirectExecutorService());
    Registered: Wed Jun 12 16:38:11 UTC 2024
    - Last Modified: Wed Sep 06 17:04:31 UTC 2023
    - 28.2K bytes
    - Viewed (0)
Back to top