Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1 - 10 of 15 for CacheStats (0.05 seconds)

  1. android/guava/src/com/google/common/cache/CacheStats.java

        return evictionCount;
      }
    
      /**
       * Returns a new {@code CacheStats} representing the difference between this {@code CacheStats}
       * and {@code other}. Negative values, which aren't supported by {@code CacheStats} will be
       * rounded up to zero.
       */
      public CacheStats minus(CacheStats other) {
        return new CacheStats(
            max(0, saturatedSubtract(hitCount, other.hitCount)),
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Tue Jul 08 18:32:10 GMT 2025
    - 12.6K bytes
    - Click Count (0)
  2. guava/src/com/google/common/cache/CacheStats.java

        return evictionCount;
      }
    
      /**
       * Returns a new {@code CacheStats} representing the difference between this {@code CacheStats}
       * and {@code other}. Negative values, which aren't supported by {@code CacheStats} will be
       * rounded up to zero.
       */
      public CacheStats minus(CacheStats other) {
        return new CacheStats(
            max(0, saturatedSubtract(hitCount, other.hitCount)),
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Tue Jul 08 18:32:10 GMT 2025
    - 12.6K bytes
    - Click Count (0)
  3. 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);
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Tue Sep 30 22:03:28 GMT 2025
    - 91.1K bytes
    - Click Count (0)
  4. 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);
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Tue Sep 30 22:03:28 GMT 2025
    - 6.4K bytes
    - Click Count (0)
  5. android/guava/src/com/google/common/cache/AbstractCache.java

          totalLoadTime.add(loadTime);
        }
    
        @Override
        public void recordEviction() {
          evictionCount.increment();
        }
    
        @Override
        public CacheStats snapshot() {
          return new CacheStats(
              negativeToMaxValue(hitCount.sum()),
              negativeToMaxValue(missCount.sum()),
              negativeToMaxValue(loadSuccessCount.sum()),
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Tue May 13 17:27:14 GMT 2025
    - 9.1K bytes
    - Click Count (0)
  6. 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);
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Tue Sep 30 22:03:28 GMT 2025
    - 91.1K bytes
    - Click Count (0)
  7. guava/src/com/google/common/cache/AbstractCache.java

          totalLoadTime.add(loadTime);
        }
    
        @Override
        public void recordEviction() {
          evictionCount.increment();
        }
    
        @Override
        public CacheStats snapshot() {
          return new CacheStats(
              negativeToMaxValue(hitCount.sum()),
              negativeToMaxValue(missCount.sum()),
              negativeToMaxValue(loadSuccessCount.sum()),
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Tue May 13 17:27:14 GMT 2025
    - 9.1K bytes
    - Click Count (0)
  8. android/guava/src/com/google/common/cache/package-info.java

     * configured and created using {@link CacheBuilder}, with cache entries being loaded by {@link
     * CacheLoader}. Statistics about cache performance are exposed using {@link CacheStats}.
     *
     * <p>See the Guava User Guide article on <a
     * href="https://github.com/google/guava/wiki/CachesExplained">caches</a>.
     *
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Fri Jan 03 19:02:39 GMT 2025
    - 1.4K bytes
    - Click Count (0)
  9. 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:
       *
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Wed Oct 08 18:55:33 GMT 2025
    - 51.9K bytes
    - Click Count (0)
  10. android/guava/src/com/google/common/cache/Cache.java

       * created using {@link CacheBuilder} only does so if the {@link CacheBuilder#recordStats} method
       * was called. If statistics are not being recorded, a {@code CacheStats} instance with zero for
       * all values is returned.
       *
       */
      CacheStats stats();
    
      /**
       * Returns a view of the entries stored in this cache as a thread-safe map. Modifications made to
       * the map directly affect the cache.
       *
    Created: Fri Dec 26 12:43:10 GMT 2025
    - Last Modified: Sun Dec 22 03:38:46 GMT 2024
    - 8.3K bytes
    - Click Count (0)
Back to Top