- Sort Score
- Num 10 results
- Language All
Results 1 - 3 of 3 for getOrLoad (0.04 seconds)
-
guava-tests/test/com/google/common/cache/LocalCacheTest.java
} }; LocalCache<String, String> cache = makeLocalCache(builder, loader); assertThat(cache.getOrLoad("test")).isEqualTo("testLoad"); ticker.advance(10, MILLISECONDS); // so that the next call will trigger refresh assertThat(cache.getOrLoad("test")).isEqualTo("testLoad"); reloadStarted.await(); ticker.advance(500, MILLISECONDS); // so that the entry expires during the reloadCreated: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Fri Dec 12 00:25:21 GMT 2025 - 117.5K bytes - Click Count (0) -
android/guava-tests/test/com/google/common/cache/LocalCacheTest.java
} }; LocalCache<String, String> cache = makeLocalCache(builder, loader); assertThat(cache.getOrLoad("test")).isEqualTo("testLoad"); ticker.advance(10, MILLISECONDS); // so that the next call will trigger refresh assertThat(cache.getOrLoad("test")).isEqualTo("testLoad"); reloadStarted.await(); ticker.advance(500, MILLISECONDS); // so that the entry expires during the reloadCreated: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Fri Dec 12 00:25:21 GMT 2025 - 115.9K bytes - Click Count (0) -
guava/src/com/google/common/cache/LocalCache.java
} @Override public @Nullable V getOrDefault(@Nullable Object key, @Nullable V defaultValue) { V result = get(key); return (result != null) ? result : defaultValue; } V getOrLoad(K key) throws ExecutionException { return get(key, defaultLoader); } ImmutableMap<K, V> getAllPresent(Iterable<?> keys) { int hits = 0; int misses = 0;
Created: Fri Dec 26 12:43:10 GMT 2025 - Last Modified: Thu Sep 11 19:35:11 GMT 2025 - 148.9K bytes - Click Count (0)