- Sort Score
- Num 10 results
- Language All
Results 1 - 5 of 5 for trimToSize (0.06 seconds)
-
guava/src/com/google/common/collect/ArrayListMultimap.java
* ImmutableListMultimap}. If you need a mutable collection, remove the {@code trimToSize} * call, or switch to a {@code HashMap<K, ArrayList<V>>}. */ @Deprecated public void trimToSize() { for (Collection<V> collection : backingMap().values()) { ArrayList<V> arrayList = (ArrayList<V>) collection; arrayList.trimToSize(); } } /**Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Fri Dec 05 23:15:58 GMT 2025 - 6.8K bytes - Click Count (0) -
android/guava-tests/test/com/google/common/collect/CompactLinkedHashMapTest.java
CompactLinkedHashMap<Integer, String> map = CompactLinkedHashMap.createWithExpectedSize(100); map.put(1, "a"); map.put(4, "b"); map.put(3, "d"); map.put(2, "c"); map.trimToSize(); assertThat(map.entries).hasLength(4); assertThat(map.keys).hasLength(4); assertThat(map.values).hasLength(4); assertThat(map.links).hasLength(4); assertEquals(4, map.size());
Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Tue Oct 28 18:44:53 GMT 2025 - 6.7K bytes - Click Count (0) -
guava-tests/test/com/google/common/collect/CompactLinkedHashMapTest.java
CompactLinkedHashMap<Integer, String> map = CompactLinkedHashMap.createWithExpectedSize(100); map.put(1, "a"); map.put(4, "b"); map.put(3, "d"); map.put(2, "c"); map.trimToSize(); assertThat(map.entries).hasLength(4); assertThat(map.keys).hasLength(4); assertThat(map.values).hasLength(4); assertThat(map.links).hasLength(4); assertEquals(4, map.size());
Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Tue Oct 28 18:44:53 GMT 2025 - 7.8K bytes - Click Count (0) -
okhttp/src/jvmTest/kotlin/okhttp3/internal/cache/DiskLruCacheTest.kt
filesystem.deleteRecursively(cacheDir) assertThat(cache["a"]).isNull() } /** * We had a long-lived bug where [DiskLruCache.trimToSize] could infinite loop if entries * being edited required deletion for the operation to complete. */ @Test fun trimToSizeWithActiveEdit() { val expectedByteCount = if (windows) 10L else 0LCreated: Fri Dec 26 11:42:13 GMT 2025 - Last Modified: Sat Nov 01 12:18:11 GMT 2025 - 59.4K bytes - Click Count (0) -
android/guava/src/com/google/common/collect/Ordering.java
ArrayList<E> list = Lists.newArrayList(iterator); sort(list, this); if (list.size() > k) { list.subList(k, list.size()).clear(); } list.trimToSize(); return unmodifiableList(list); } else { TopKSelector<E> selector = TopKSelector.least(k, this); selector.offerAll(iterator); return selector.topK(); } } /**
Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Tue Sep 23 17:50:58 GMT 2025 - 39.5K bytes - Click Count (0)