Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1 - 7 of 7 for SimpleStatsCounter (0.17 seconds)

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

        StatsCounter counter = new SimpleStatsCounter();
        counter.recordLoadSuccess(Long.MAX_VALUE);
        counter.recordLoadSuccess(1);
        CacheStats stats = counter.snapshot();
        assertThat(stats.totalLoadTime()).isEqualTo(Long.MAX_VALUE);
      }
    
      public void testSimpleStatsIncrementBy() {
        long totalLoadTime = 0;
    
        SimpleStatsCounter counter1 = new SimpleStatsCounter();
        for (int i = 0; i < 11; i++) {
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Tue Sep 30 22:03:28 GMT 2025
    - 6.4K bytes
    - Click Count (0)
  2. android/guava/src/com/google/common/cache/AbstractCache.java

         */
        CacheStats snapshot();
      }
    
      /**
       * A thread-safe {@link StatsCounter} implementation for use by {@link Cache} implementors.
       *
       * @since 10.0
       */
      public static final class SimpleStatsCounter implements StatsCounter {
        private final LongAddable hitCount = LongAddables.create();
        private final LongAddable missCount = LongAddables.create();
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Tue May 13 17:27:14 GMT 2025
    - 9.1K bytes
    - Click Count (0)
  3. guava/src/com/google/common/cache/AbstractCache.java

         */
        CacheStats snapshot();
      }
    
      /**
       * A thread-safe {@link StatsCounter} implementation for use by {@link Cache} implementors.
       *
       * @since 10.0
       */
      public static final class SimpleStatsCounter implements StatsCounter {
        private final LongAddable hitCount = LongAddables.create();
        private final LongAddable missCount = LongAddables.create();
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Tue Mar 03 12:40:22 GMT 2026
    - 9.2K bytes
    - Click Count (0)
  4. android/guava/src/com/google/common/cache/CacheBuilder.java

    import com.google.common.base.MoreObjects;
    import com.google.common.base.Supplier;
    import com.google.common.base.Suppliers;
    import com.google.common.base.Ticker;
    import com.google.common.cache.AbstractCache.SimpleStatsCounter;
    import com.google.common.cache.AbstractCache.StatsCounter;
    import com.google.common.cache.LocalCache.Strength;
    import com.google.errorprone.annotations.CanIgnoreReturnValue;
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Mon Feb 23 13:13:59 GMT 2026
    - 52K bytes
    - Click Count (0)
  5. guava/src/com/google/common/cache/CacheBuilder.java

    import com.google.common.base.MoreObjects;
    import com.google.common.base.Supplier;
    import com.google.common.base.Suppliers;
    import com.google.common.base.Ticker;
    import com.google.common.cache.AbstractCache.SimpleStatsCounter;
    import com.google.common.cache.AbstractCache.StatsCounter;
    import com.google.common.cache.LocalCache.Strength;
    import com.google.errorprone.annotations.CanIgnoreReturnValue;
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Mon Feb 23 13:13:59 GMT 2026
    - 51.7K bytes
    - Click Count (0)
  6. android/guava/src/com/google/common/cache/LocalCache.java

        }
    
        @Override
        public ConcurrentMap<K, V> asMap() {
          return localCache;
        }
    
        @Override
        public CacheStats stats() {
          SimpleStatsCounter aggregator = new SimpleStatsCounter();
          aggregator.incrementBy(localCache.globalStatsCounter);
          for (Segment<K, V> segment : localCache.segments) {
            aggregator.incrementBy(segment.statsCounter);
          }
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Wed Apr 01 17:27:13 GMT 2026
    - 143.5K bytes
    - Click Count (0)
  7. guava/src/com/google/common/cache/LocalCache.java

        }
    
        @Override
        public ConcurrentMap<K, V> asMap() {
          return localCache;
        }
    
        @Override
        public CacheStats stats() {
          SimpleStatsCounter aggregator = new SimpleStatsCounter();
          aggregator.incrementBy(localCache.globalStatsCounter);
          for (Segment<K, V> segment : localCache.segments) {
            aggregator.incrementBy(segment.statsCounter);
          }
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Wed Apr 01 17:27:13 GMT 2026
    - 148.9K bytes
    - Click Count (0)
Back to Top