Search Options

Results per page
Sort
Preferred Languages
Advance

Results 21 - 30 of 140 for Tucker (0.16 sec)

  1. guava/src/com/google/common/cache/LocalCache.java

          this.maxWeight = maxWeight;
          this.weigher = weigher;
          this.concurrencyLevel = concurrencyLevel;
          this.removalListener = removalListener;
          this.ticker = (ticker == Ticker.systemTicker() || ticker == NULL_TICKER) ? null : ticker;
          this.loader = loader;
        }
    
        CacheBuilder<K, V> recreateCacheBuilder() {
          CacheBuilder<K, V> builder =
              CacheBuilder.newBuilder()
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 22 17:40:56 GMT 2024
    - 150.3K bytes
    - Viewed (0)
  2. android/guava-testlib/test/com/google/common/testing/FakeTickerTest.java

      public void testAdvance() {
        FakeTicker ticker = new FakeTicker();
        assertEquals(0, ticker.read());
        assertSame(ticker, ticker.advance(10));
        assertEquals(10, ticker.read());
        ticker.advance(1, TimeUnit.MILLISECONDS);
        assertEquals(1000010L, ticker.read());
        ticker.advance(Duration.ofMillis(1));
        assertEquals(2000010L, ticker.read());
      }
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Feb 06 14:40:46 GMT 2024
    - 6.4K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/cache/CacheExpirationTest.java

                .expireAfterWrite(EXPIRING_TIME, MILLISECONDS)
                .removalListener(removalListener)
                .ticker(ticker)
                .build(loader);
        checkExpiration(cache, loader, ticker, removalListener);
      }
    
      public void testExpiration_expireAfterAccess() {
        FakeTicker ticker = new FakeTicker();
        CountingRemovalListener<String, Integer> removalListener = countingRemovalListener();
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Fri Aug 05 17:21:46 GMT 2022
    - 18.7K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/base/StopwatchTest.java

      }
    
      public void testElapsed_notRunning() {
        ticker.advance(1);
        stopwatch.start();
        ticker.advance(4);
        stopwatch.stop();
        ticker.advance(9);
        assertEquals(4, stopwatch.elapsed(NANOSECONDS));
      }
    
      public void testElapsed_multipleSegments() {
        stopwatch.start();
        ticker.advance(9);
        stopwatch.stop();
    
        ticker.advance(16);
    
        stopwatch.start();
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Fri Feb 09 15:49:48 GMT 2024
    - 5.8K bytes
    - Viewed (0)
  5. guava/src/com/google/common/base/Stopwatch.java

       *
       * @since 15.0
       */
      public static Stopwatch createStarted(Ticker ticker) {
        return new Stopwatch(ticker).start();
      }
    
      Stopwatch() {
        this.ticker = Ticker.systemTicker();
      }
    
      Stopwatch(Ticker ticker) {
        this.ticker = checkNotNull(ticker, "ticker");
      }
    
      /**
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 23 15:09:35 GMT 2023
    - 9.2K bytes
    - Viewed (0)
  6. guava-tests/test/com/google/common/cache/CacheLoadingTest.java

                return Futures.immediateFuture(two);
              }
            };
    
        LoadingCache<Object, Object> cache =
            CacheBuilder.newBuilder()
                .recordStats()
                .ticker(ticker)
                .refreshAfterWrite(1, MILLISECONDS)
                .build(loader);
        Object key = new Object();
        CacheStats stats = cache.stats();
        assertEquals(0, stats.missCount());
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 86.2K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/base/Ticker.java

    @ElementTypesAreNonnullByDefault
    public abstract class Ticker {
      /** Constructor for use by subclasses. */
      protected Ticker() {}
    
      /** Returns the number of nanoseconds elapsed since this ticker's fixed point of reference. */
      public abstract long read();
    
      /**
       * A ticker that reads the current time using {@link System#nanoTime}.
       *
       * @since 10.0
       */
      public static Ticker systemTicker() {
        return SYSTEM_TICKER;
      }
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue May 23 23:27:53 GMT 2023
    - 1.8K bytes
    - Viewed (0)
  8. guava-tests/test/com/google/common/io/TestStreamSupplier.java

     * stream was closed. Intended for use in a test where only a single stream should be opened and
     * possibly closed.
     *
     * @author Colin Decker
     */
    public interface TestStreamSupplier {
    
      /** Returns whether or not a new stream was opened. */
      boolean wasStreamOpened();
    
      /** Returns whether or not an open stream was closed. */
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 1.1K bytes
    - Viewed (0)
  9. android/guava-testlib/src/com/google/common/collect/testing/google/GoogleHelpers.java

    import com.google.common.annotations.GwtCompatible;
    import com.google.common.collect.Multimap;
    
    /**
     * Helper methods/assertions for use with {@code com.google.common.collect} types.
     *
     * @author Colin Decker
     */
    @GwtCompatible
    final class GoogleHelpers {
    
      private GoogleHelpers() {}
    
      static void assertEmpty(Multimap<?, ?> multimap) {
        if (!multimap.isEmpty()) {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Fri Apr 21 02:27:51 GMT 2017
    - 1.1K bytes
    - Viewed (0)
  10. android/guava-tests/test/com/google/common/io/TestCharSource.java

    import java.io.IOException;
    import java.io.InputStreamReader;
    import java.io.Reader;
    
    /**
     * A char source for testing that has configurable options.
     *
     * @author Colin Decker
     */
    public class TestCharSource extends CharSource implements TestStreamSupplier {
    
      private final TestByteSource byteSource;
    
      public TestCharSource(String content, TestOption... options) {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Fri Apr 21 02:27:51 GMT 2017
    - 1.4K bytes
    - Viewed (0)
Back to top