Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 703 for topo (0.15 sec)

  1. guava-tests/test/com/google/common/collect/TopKSelectorTest.java

        TopKSelector<Integer> top = TopKSelector.least(0);
        for (int i = 0; i < 10; i++) {
          top.offer(i);
        }
        assertThat(top.topK()).isEmpty();
      }
    
      public void testNoElementsOffered() {
        TopKSelector<Integer> top = TopKSelector.least(10);
        assertThat(top.topK()).isEmpty();
      }
    
      public void testOfferedFewerThanK() {
        TopKSelector<Integer> top = TopKSelector.least(10);
        top.offer(3);
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Mar 07 18:34:03 GMT 2024
    - 3.9K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/reflect/ClassPath.java

          try {
            if (!file.exists()) {
              return;
            }
          } catch (SecurityException e) {
            logger.warning("Cannot access " + file + ": " + e);
            // TODO(emcmanus): consider whether to log other failure cases too.
            return;
          }
          if (file.isDirectory()) {
            scanDirectory(file, builder);
          } else {
            scanJar(file, scannedUris, builder);
          }
        }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Jan 05 17:43:40 GMT 2022
    - 24.9K bytes
    - Viewed (1)
  3. guava-testlib/src/com/google/common/collect/testing/google/MultisetSetCountConditionallyTester.java

      public void testSetCountConditional_oldCountTooSmallNonzero() {
        initThreeCopies();
        assertFalse(
            "setCount() with a too-small oldCount should return false",
            getMultiset().setCount(e0(), 1, 5));
        expectContents(nCopies(3, e0()));
      }
    
      /*
       * TODO: test that unmodifiable multisets either throw UOE or return false
       * when both are valid options. Currently we test the UOE cases and the
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Sep 21 15:08:35 GMT 2022
    - 3.9K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/primitives/UnsignedLong.java

       */
      @Override
      public float floatValue() {
        if (value >= 0) {
          return (float) value;
        }
        // The top bit is set, which means that the float value is going to come from the top 24 bits.
        // So we can ignore the bottom 8, except for rounding. See doubleValue() for more.
        return (float) ((value >>> 1) | (value & 1)) * 2f;
      }
    
      /**
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Apr 22 13:09:25 GMT 2021
    - 8.9K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/math/LongMathTest.java

        }
      }
    
      @GwtIncompatible // TODO
      public void testPow() {
        for (long i : ALL_LONG_CANDIDATES) {
          for (int exp : EXPONENTS) {
            assertEquals(LongMath.pow(i, exp), valueOf(i).pow(exp).longValue());
          }
        }
      }
    
      @J2ktIncompatible // J2kt BigDecimal.divide also has the rounding bug
      @GwtIncompatible // TODO
      @AndroidIncompatible // TODO(cpovirk): File BigDecimal.divide() rounding bug.
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Mar 04 20:15:57 GMT 2024
    - 32.5K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/util/concurrent/UninterruptibleFutureTest.java

            () -> getUninterruptibly(delayedFuture, 500, TimeUnit.MILLISECONDS));
        assertTrue(Thread.interrupted()); // clears the interrupt state, too
    
        assertFalse(sleeper.completed);
        assertTrue(getUninterruptibly(delayedFuture));
    
        assertTrue(Thread.interrupted()); // clears the interrupt state, too
        assertTrue(sleeper.completed);
      }
    
      private static class SleepingRunnable implements Runnable {
        final int millis;
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 9.1K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/collect/Platform.java

       *
       * - https://github.com/jspecify/jspecify/issues/65
       *
       * - https://github.com/jspecify/jdk/commit/71d826792b8c7ef95d492c50a274deab938f2552
       */
      /*
       * TODO(cpovirk): Is the unchecked cast avoidable? Would System.arraycopy be similarly fast (if
       * likewise not type-checked)? Could our single caller do something different?
       */
      @SuppressWarnings({"nullness", "unchecked"})
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 4.9K bytes
    - Viewed (0)
  8. android/guava-tests/test/com/google/common/util/concurrent/InterruptibleTaskTest.java

       * protect ourselves from that we want to make sure that tasks don't spin too much waiting for the
       * interrupting thread to complete the protocol.
       */
      /*
       * This test hangs (or maybe is just *very* slow) under Android.
       *
       * TODO(b/218700094): Ideally, get this to pass under Android. Failing that, convince ourselves
    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)
  9. guava-tests/test/com/google/common/util/concurrent/UninterruptiblesTest.java

         * generous than it needs to be.
         */
        assertTrue(
            "Expected elapsed millis to be >= " + expectedMillis + " but was " + elapsedMillis,
            elapsedMillis + 5 >= expectedMillis);
      }
    
      // TODO(cpovirk): Split this into separate CountDownLatch and IncrementableCountDownLatch classes.
    
      /** Manages a {@link BlockingQueue} and associated timings for a {@code put} call. */
      private static final class TimedPutQueue {
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Feb 09 22:57:07 GMT 2022
    - 31.7K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/primitives/Chars.java

       *
       * @param value any {@code long} value
       * @return the same value cast to {@code char} if it is in the range of the {@code char} type,
       *     {@link Character#MAX_VALUE} if it is too large, or {@link Character#MIN_VALUE} if it is too
       *     small
       */
      public static char saturatedCast(long value) {
        if (value > Character.MAX_VALUE) {
          return Character.MAX_VALUE;
        }
        if (value < Character.MIN_VALUE) {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 15 16:12:13 GMT 2024
    - 23.5K bytes
    - Viewed (0)
Back to top