Search Options

Results per page
Sort
Preferred Languages
Advance

Results 31 - 40 of 443 for whale (0.24 sec)

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

     * desirable to use in some unit tests. More importantly, attempting to debug a call which is
     * time-limited would be extremely annoying, so this gives you a time-limiter you can easily swap in
     * for your real time-limiter while you're debugging.
     *
     * @author Kevin Bourrillion
     * @author Jens Nyman
     * @since 1.0
     */
    @J2ktIncompatible
    @GwtIncompatible
    @ElementTypesAreNonnullByDefault
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Dec 14 20:35:03 GMT 2023
    - 3.5K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/util/concurrent/ImmediateFuture.java

          // runnable and/or executor and swallow it.
          log.get()
              .log(
                  Level.SEVERE,
                  "RuntimeException while executing runnable "
                      + listener
                      + " with executor "
                      + executor,
                  e);
        }
      }
    
      @Override
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Dec 13 19:45:20 GMT 2023
    - 3.5K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/hash/BloomFilterTest.java

        BloomFilter<Object> bf = BloomFilter.create(HashTestUtils.BAD_FUNNEL, 10, 0.03);
        double fpp = bf.expectedFpp();
        assertEquals(0.0, fpp);
        // usually completed in less than 200 iterations
        while (fpp != 1.0) {
          boolean changed = bf.put(new Object());
          double newFpp = bf.expectedFpp();
          // if changed, the new fpp is strictly higher, otherwise it is the same
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Nov 09 22:49:56 GMT 2023
    - 21.3K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/util/concurrent/ListenableFutureTaskTest.java

        assertEquals(1, runLatch.getCount());
      }
    
      public void testListenerCalledOnCancelFromRunning() throws Exception {
        exec.execute(task);
        runLatch.await();
    
        // Task has started up, cancel it while it's running.
        task.cancel(true);
        assertTrue(task.isDone());
        assertTrue(task.isCancelled());
        assertEquals(1, taskLatch.getCount());
    
        // Wait for the listeners to be called.
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 4.7K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/escape/ArrayBasedCharEscaperTest.java

              }
            };
        EscaperAsserts.assertBasic(replacingEscaper);
    
        // Replacements are applied first regardless of whether the character is in
        // the safe range or not ('&' is a safe char while '\t' and '\n' are not).
        assertEquals(
            "<tab>Fish <and>? Chips?<newline>", replacingEscaper.escape("\tFish &\0 Chips\r\n"));
      }
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Feb 07 23:02:38 GMT 2024
    - 3.5K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/hash/FunnelsTest.java

              @Override
              protected HashCode makeHash() {
                throw new UnsupportedOperationException();
              }
    
              @Override
              protected void process(ByteBuffer bb) {
                while (bb.hasRemaining()) {
                  bb.get();
                }
              }
            };
        try {
          funnel.funnel(null, primitiveSink);
          fail();
        } catch (NullPointerException ok) {
        }
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Fri Oct 02 16:24:50 GMT 2020
    - 5.9K bytes
    - Viewed (0)
  7. android/guava-testlib/src/com/google/common/collect/testing/google/UnmodifiableCollectionTests.java

      /**
       * Verifies that an Iterator is unmodifiable.
       *
       * <p>This test only works with iterators that iterate over a finite set.
       */
      public static void assertIteratorIsUnmodifiable(Iterator<?> iterator) {
        while (iterator.hasNext()) {
          iterator.next();
          try {
            iterator.remove();
            fail("Remove on unmodifiable iterator succeeded");
          } catch (UnsupportedOperationException expected) {
          }
        }
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Feb 26 19:46:10 GMT 2024
    - 14.8K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/collect/Comparators.java

          Iterable<? extends T> iterable, Comparator<T> comparator) {
        checkNotNull(comparator);
        Iterator<? extends T> it = iterable.iterator();
        if (it.hasNext()) {
          T prev = it.next();
          while (it.hasNext()) {
            T next = it.next();
            if (comparator.compare(prev, next) > 0) {
              return false;
            }
            prev = next;
          }
        }
        return true;
      }
    
      /**
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed May 01 18:44:57 GMT 2024
    - 10.2K bytes
    - Viewed (0)
  9. guava-tests/benchmark/com/google/common/base/WhitespaceMatcherBenchmark.java

          result[i] = allMatchingChars.charAt(random.nextInt(allMatchingChars.length()));
        }
        // Replace some of chars by non-matching.
        int remaining = (int) ((100 - percentMatching) * result.length / 100.0 + 0.5);
        while (remaining > 0) {
          final char c = (char) random.nextInt();
          if (bitSet.get(c)) {
            final int pos = random.nextInt(result.length);
            if (bitSet.get(result[pos])) {
              result[pos] = c;
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed May 16 22:49:59 GMT 2018
    - 3.9K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/util/concurrent/NullnessCasts.java

       *
       * <p>Why <i>not</i> just add {@code SuppressWarnings}? The problem is that this method is
       * typically useful for {@code return} statements. That leaves the code with two options: Either
       * add the suppression to the whole method (which turns off checking for a large section of code),
       * or extract a variable, and put the suppression on that. However, a local variable typically
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Feb 10 20:36:34 GMT 2022
    - 3.9K bytes
    - Viewed (0)
Back to top