Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 7 of 7 for CacheStats (0.03 sec)

  1. android/guava-tests/test/com/google/common/cache/CacheLoadingTest.java

      }
    
      public void testLoad() throws ExecutionException {
        LoadingCache<Object, Object> cache =
            CacheBuilder.newBuilder().recordStats().build(identityLoader());
        CacheStats stats = cache.stats();
        assertThat(stats.missCount()).isEqualTo(0);
        assertThat(stats.loadSuccessCount()).isEqualTo(0);
        assertThat(stats.loadExceptionCount()).isEqualTo(0);
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Tue Sep 30 22:03:28 UTC 2025
    - 91.1K bytes
    - Viewed (0)
  2. guava-tests/test/com/google/common/cache/AbstractCacheTest.java

        cache.invalidateAll(toInvalidate);
        assertThat(invalidated).isEqualTo(toInvalidate);
      }
    
      public void testEmptySimpleStats() {
        StatsCounter counter = new SimpleStatsCounter();
        CacheStats stats = counter.snapshot();
        assertThat(stats.requestCount()).isEqualTo(0);
        assertThat(stats.hitCount()).isEqualTo(0);
        assertThat(stats.hitRate()).isEqualTo(1.0);
        assertThat(stats.missCount()).isEqualTo(0);
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Tue Sep 30 22:03:28 UTC 2025
    - 6.4K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/cache/CacheLoadingTest.java

      }
    
      public void testLoad() throws ExecutionException {
        LoadingCache<Object, Object> cache =
            CacheBuilder.newBuilder().recordStats().build(identityLoader());
        CacheStats stats = cache.stats();
        assertThat(stats.missCount()).isEqualTo(0);
        assertThat(stats.loadSuccessCount()).isEqualTo(0);
        assertThat(stats.loadExceptionCount()).isEqualTo(0);
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Tue Sep 30 22:03:28 UTC 2025
    - 91.1K bytes
    - Viewed (0)
  4. android/guava/src/com/google/common/cache/CacheBuilder.java

                @Override
                public void recordEviction() {}
    
                @Override
                public CacheStats snapshot() {
                  return EMPTY_STATS;
                }
              });
      static final CacheStats EMPTY_STATS = new CacheStats(0, 0, 0, 0, 0, 0);
    
      /*
       * We avoid using a method reference or lambda here for now:
       *
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Wed Oct 08 18:55:33 UTC 2025
    - 51.9K bytes
    - Viewed (0)
  5. android/guava-tests/test/com/google/common/cache/LocalLoadingCacheTest.java

        LocalLoadingCache<Object, Object> cache = makeCache(builder, identityLoader());
        assertThat(cache.stats()).isEqualTo(EMPTY_STATS);
    
        Object one = new Object();
        cache.getUnchecked(one);
        CacheStats stats = cache.stats();
        assertThat(stats.requestCount()).isEqualTo(1);
        assertThat(stats.hitCount()).isEqualTo(0);
        assertThat(stats.hitRate()).isEqualTo(0.0);
        assertThat(stats.missCount()).isEqualTo(1);
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Tue Oct 28 16:03:47 UTC 2025
    - 13.3K bytes
    - Viewed (0)
  6. guava/src/com/google/common/cache/CacheBuilder.java

                @Override
                public void recordEviction() {}
    
                @Override
                public CacheStats snapshot() {
                  return EMPTY_STATS;
                }
              });
      static final CacheStats EMPTY_STATS = new CacheStats(0, 0, 0, 0, 0, 0);
    
      /*
       * We avoid using a method reference or lambda here for now:
       *
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Wed Oct 08 18:55:33 UTC 2025
    - 51.6K bytes
    - Viewed (0)
  7. android/guava-tests/test/com/google/common/cache/CacheBuilderTest.java

          assertWithMessage("Invalid removal notification")
              .that(notification.getValue())
              .isEqualTo(notification.getKey());
        }
    
        CacheStats stats = cache.stats();
        assertThat(stats.evictionCount()).isEqualTo(removalListener.size());
        assertThat(stats.loadSuccessCount()).isEqualTo(computeCount.get());
    Registered: Fri Dec 26 12:43:10 UTC 2025
    - Last Modified: Tue Sep 30 22:03:28 UTC 2025
    - 25.4K bytes
    - Viewed (0)
Back to top