Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 39 for evict (0.17 sec)

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

        // evict 3, 4, 5
        getAll(cache, asList(10));
        CacheTesting.drainRecencyQueues(cache);
        assertThat(keySet).containsExactly(6, 7, 8, 9, 0, 1, 2, 10);
    
        // re-order
        getAll(cache, asList(6, 7, 8));
        CacheTesting.drainRecencyQueues(cache);
        assertThat(keySet).containsExactly(9, 0, 1, 2, 10, 6, 7, 8);
    
        // evict 9, 1, 2, 10
        getAll(cache, asList(15));
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 14.9K bytes
    - Viewed (0)
  2. android/guava-tests/test/com/google/common/cache/CacheEvictionTest.java

        // evict 3, 4, 5
        getAll(cache, asList(10));
        CacheTesting.drainRecencyQueues(cache);
        assertThat(keySet).containsExactly(6, 7, 8, 9, 0, 1, 2, 10);
    
        // re-order
        getAll(cache, asList(6, 7, 8));
        CacheTesting.drainRecencyQueues(cache);
        assertThat(keySet).containsExactly(9, 0, 1, 2, 10, 6, 7, 8);
    
        // evict 9, 1, 2, 10
        getAll(cache, asList(15));
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 14.9K bytes
    - Viewed (0)
  3. okhttp/src/test/java/okhttp3/internal/cache/DiskLruCacheTest.kt

        assertThat(cache.size()).isEqualTo(10)
    
        // Cause the size to grow to 12 should evict 'A'.
        set("c", "c", "c")
        cache.flush()
        assertThat(cache.size()).isEqualTo(8)
        assertAbsent("a")
        assertValue("b", "bb", "bbbb")
        assertValue("c", "c", "c")
    
        // Causing the size to grow to 10 should evict nothing.
        set("d", "d", "d")
        cache.flush()
        assertThat(cache.size()).isEqualTo(10)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Apr 15 14:55:09 GMT 2024
    - 75.8K bytes
    - Viewed (0)
  4. okhttp/src/main/kotlin/okhttp3/internal/connection/RealConnectionPool.kt

          }
    
          else -> {
            toEvict = null
            toEvictIdleAtNs = -1L
          }
        }
    
        when {
          toEvict != null -> {
            // We've chosen a connection to evict. Confirm it's still okay to be evicted, then close it.
            toEvict.withLock {
              if (toEvict.calls.isNotEmpty()) return 0L // No longer idle.
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Sat Apr 20 17:03:43 GMT 2024
    - 16.2K bytes
    - Viewed (0)
  5. guava/src/com/google/common/cache/CacheBuilder.java

       *
       * <p>Note that the cache <b>may evict an entry before this limit is exceeded</b>. For example, in
       * the current implementation, when {@code concurrencyLevel} is greater than {@code 1}, each
       * resulting segment inside the cache <i>independently</i> limits its own size to approximately
       * {@code maximumSize / concurrencyLevel}.
       *
       * <p>When eviction is necessary, the cache evicts entries that are less likely to be used again.
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 15 16:12:13 GMT 2024
    - 51.3K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/cache/CacheBuilder.java

       *
       * <p>Note that the cache <b>may evict an entry before this limit is exceeded</b>. For example, in
       * the current implementation, when {@code concurrencyLevel} is greater than {@code 1}, each
       * resulting segment inside the cache <i>independently</i> limits its own size to approximately
       * {@code maximumSize / concurrencyLevel}.
       *
       * <p>When eviction is necessary, the cache evicts entries that are less likely to be used again.
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 15 16:12:13 GMT 2024
    - 44.8K bytes
    - Viewed (0)
  7. okhttp/src/main/kotlin/okhttp3/internal/http2/Hpack.kt

            }
    
            // if the new or replacement header is too big, drop all entries.
            if (delta > maxDynamicTableByteCount) {
              clearDynamicTable()
              return
            }
    
            // Evict headers to the required length.
            val bytesToRecover = dynamicTableByteCount + delta - maxDynamicTableByteCount
            val entriesEvicted = evictToRecoverBytes(bytesToRecover)
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 22.5K bytes
    - Viewed (1)
  8. android/guava/src/com/google/common/collect/MinMaxPriorityQueue.java

      @Override
      public int size() {
        return size;
      }
    
      /**
       * Adds the given element to this queue. If this queue has a maximum size, after adding {@code
       * element} the queue will automatically evict its greatest element (according to its comparator),
       * which may be {@code element} itself.
       *
       * @return {@code true} always
       */
      @CanIgnoreReturnValue
      @Override
      public boolean add(E element) {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 22 21:19:52 GMT 2024
    - 34K bytes
    - Viewed (0)
  9. okhttp/src/test/java/okhttp3/ConnectionReuseTest.kt

            .build()
        val request = Request(server.url("/"))
        val response1 = client.newCall(request).execute()
        assertThat(response1.body.string()).isEqualTo("a")
    
        // Give the thread pool a chance to evict.
        Thread.sleep(500)
        val response2 = client.newCall(request).execute()
        assertThat(response2.body.string()).isEqualTo("b")
        assertThat(server.takeRequest().sequenceNumber).isEqualTo(0)
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Mon Jan 08 01:13:22 GMT 2024
    - 12.3K bytes
    - Viewed (0)
  10. okhttp/src/test/java/okhttp3/internal/connection/ConnectionPoolTest.kt

            maxIdleConnections = 2,
          )
        val c1 = factory.newConnection(pool, routeA1, 50L)
        val c2 = factory.newConnection(pool, routeB1, 75L)
    
        // With 2 connections, there's no need to evict until the connections time out.
        assertThat(pool.closeConnections(100L)).isEqualTo(50L)
        assertThat(pool.connectionCount()).isEqualTo(2)
        assertThat(c1.socket().isClosed).isFalse()
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 24 04:40:49 GMT 2024
    - 12.7K bytes
    - Viewed (0)
Back to top