Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 16 for evict (0.13 sec)

  1. 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)
  2. 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)
  3. 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)
  4. 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)
  5. okhttp/src/main/kotlin/okhttp3/Cache.kt

       * (unless they were already returned).
       *
       * The iterator supports [MutableIterator.remove]. Removing a URL from the iterator evicts the
       * corresponding response from the cache. Use this to evict selected responses.
       */
      @Throws(IOException::class)
      fun urls(): MutableIterator<String> {
        return object : MutableIterator<String> {
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 10 19:46:48 GMT 2024
    - 26.8K bytes
    - Viewed (0)
  6. common-protos/k8s.io/api/core/v1/generated.proto

      // of effect NoExecute, otherwise this field is ignored) tolerates the taint. By default,
      // it is not set, which means tolerate the taint forever (do not evict). Zero and
      // negative values will be treated as 0 (evict immediately) by the system.
      // +optional
      optional int64 tolerationSeconds = 5;
    }
    
    // A topology selector requirement is a selector that matches given label.
    Plain Text
    - Registered: Wed May 08 22:53:08 GMT 2024
    - Last Modified: Mon Mar 11 18:43:24 GMT 2024
    - 255.8K bytes
    - Viewed (0)
  7. guava-tests/test/com/google/common/cache/LocalCacheTest.java

          int hash = map.hash(key);
          assertNull(segment.put(key, hash, value, false));
          assertTrue(segment.table.length() > i);
        }
      }
    
      public void testSegmentPut_evict() {
        int maxSize = 10;
        LocalCache<Object, Object> map =
            makeLocalCache(createCacheBuilder().concurrencyLevel(1).maximumSize(maxSize));
    
        // manually add elements to avoid eviction
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Mar 14 23:06:48 GMT 2024
    - 112.3K bytes
    - Viewed (0)
  8. android/guava-tests/test/com/google/common/cache/LocalCacheTest.java

          int hash = map.hash(key);
          assertNull(segment.put(key, hash, value, false));
          assertTrue(segment.table.length() > i);
        }
      }
    
      public void testSegmentPut_evict() {
        int maxSize = 10;
        LocalCache<Object, Object> map =
            makeLocalCache(createCacheBuilder().concurrencyLevel(1).maximumSize(maxSize));
    
        // manually add elements to avoid eviction
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Mar 14 23:06:48 GMT 2024
    - 110.7K bytes
    - Viewed (0)
  9. okhttp/src/test/java/okhttp3/CacheTest.kt

        assertThat(get(url).body.string()).isEqualTo("a")
    
        // The URL will remain available if hasNext() returned true...
        val i = cache.urls()
        assertThat(i.hasNext()).isTrue()
    
        // ...so even when we evict the element, we still get something back.
        cache.evictAll()
        assertThat(i.next()).isEqualTo(url.toString())
    
        // Remove does nothing. But most importantly, it doesn't throw!
        i.remove()
      }
    
    Plain Text
    - Registered: Fri May 03 11:42:14 GMT 2024
    - Last Modified: Wed Apr 10 19:46:48 GMT 2024
    - 108.6K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/cache/LocalCache.java

       * across different segments.
       *
       * If a maximum size is specified, a best-effort bounding is performed per segment, using a
       * page-replacement algorithm to determine which entries to evict when the capacity has been
       * exceeded.
       *
       * The page replacement algorithm's data structures are kept casually consistent with the map. The
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 22 17:40:56 GMT 2024
    - 144.7K bytes
    - Viewed (0)
Back to top