- Sort Score
- Result 10 results
- Languages All
Results 21 - 30 of 271 for cache (0.15 sec)
-
android/guava/src/com/google/common/cache/CacheLoader.java
* @param function the function to be used for loading values; must never return {@code null} * @return a cache loader that loads values by passing each key to {@code function} */ public static <K, V> CacheLoader<K, V> from(Function<K, V> function) { return new FunctionToCacheLoader<>(function); } /** * Returns a cache loader based on an <i>existing</i> supplier instance. Note that there's no need
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Mon Dec 19 20:20:14 GMT 2022 - 9.6K bytes - Viewed (0) -
samples/crawler/src/main/java/okhttp3/sample/Crawler.java
if (args.length != 2) { System.out.println("Usage: Crawler <cache dir> <root>"); return; } int threadCount = 20; long cacheByteCount = 1024L * 1024L * 100L; Cache cache = new Cache(new File(args[0]), cacheByteCount); OkHttpClient client = new OkHttpClient.Builder() .cache(cache) .build(); Crawler crawler = new Crawler(client);
Java - Registered: Fri May 03 11:42:14 GMT 2024 - Last Modified: Thu Aug 12 07:26:27 GMT 2021 - 4.6K bytes - Viewed (0) -
android/guava/src/com/google/common/cache/ForwardingLoadingCache.java
* the License. */ package com.google.common.cache; import com.google.common.annotations.GwtIncompatible; import com.google.common.base.Preconditions; import com.google.common.collect.ImmutableMap; import com.google.errorprone.annotations.CanIgnoreReturnValue; import java.util.concurrent.ExecutionException; /** * A cache which forwards all its method calls to another cache. Subclasses should override one or
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Sat Aug 06 17:12:03 GMT 2022 - 2.9K bytes - Viewed (0) -
guava-tests/test/com/google/common/cache/CacheLoadingTest.java
* the License. */ package com.google.common.cache; import static com.google.common.cache.TestingCacheLoaders.bulkLoader; import static com.google.common.cache.TestingCacheLoaders.constantLoader; import static com.google.common.cache.TestingCacheLoaders.errorLoader; import static com.google.common.cache.TestingCacheLoaders.exceptionLoader; import static com.google.common.cache.TestingCacheLoaders.identityLoader;
Java - Registered: Fri Apr 19 12:43:09 GMT 2024 - Last Modified: Wed Sep 06 17:04:31 GMT 2023 - 86.2K bytes - Viewed (0) -
maven-api-impl/src/main/java/org/apache/maven/api/services/model/ModelCache.java
import java.util.function.Supplier; import org.apache.maven.api.services.Source; /** * Caches auxiliary data used during model building like already processed raw/effective models. The data in the cache * is meant for exclusive consumption by the model builder and is opaque to the cache implementation. The cache key is * formed by a combination of group id, artifact id, version and tag. The first three components generally refer to the
Java - Registered: Sun Apr 28 03:35:10 GMT 2024 - Last Modified: Fri Apr 12 10:50:18 GMT 2024 - 1.6K bytes - Viewed (0) -
maven-core/src/main/java/org/apache/maven/plugin/DefaultPluginArtifactsCache.java
assertUniqueKey(key); CacheRecord record = new CacheRecord(Collections.unmodifiableList(new ArrayList<>(pluginArtifacts))); cache.put(key, record); return record; } protected void assertUniqueKey(Key key) { if (cache.containsKey(key)) { throw new IllegalStateException("Duplicate artifact resolution result for plugin " + key); } }
Java - Registered: Sun May 05 03:35:11 GMT 2024 - Last Modified: Wed Sep 06 08:39:32 GMT 2023 - 5.8K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/cache/ForwardingCacheTest.java
import junit.framework.TestCase; /** * Unit test for {@link ForwardingCache}. * * @author Charles Fry */ public class ForwardingCacheTest extends TestCase { private Cache<String, Boolean> forward; private Cache<String, Boolean> mock; @SuppressWarnings({"unchecked", "DoNotMock"}) // mock @Override public void setUp() throws Exception { super.setUp(); /*
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Mon Apr 17 12:41:04 GMT 2023 - 3.1K bytes - Viewed (0) -
guava-tests/benchmark/com/google/common/cache/ChainBenchmark.java
LocalCache<Object, Object> cache = new LocalCache<>(CacheBuilder.newBuilder().concurrencyLevel(1), null); segment = cache.segments[0]; chain = null; for (int i = 0; i < length; i++) { Object key = new Object(); // TODO(b/145386688): This access should be guarded by 'this.segment', which is not currently // held chain = segment.newEntry(key, cache.hash(key), chain); if (i == 0) {
Java - Registered: Fri Apr 19 12:43:09 GMT 2024 - Last Modified: Mon Apr 17 15:19:38 GMT 2023 - 2.1K bytes - Viewed (0) -
guava/src/com/google/common/cache/LoadingCache.java
* Cache.asMap().putIfAbsent} after loading has completed; if another value was associated with * {@code key} while the new value was loading then a removal notification will be sent for the * new value. * * <p>If the cache loader associated with this cache is known not to throw checked exceptions, * then prefer {@link #getUnchecked} over this method. *
Java - Registered: Fri Apr 05 12:43:09 GMT 2024 - Last Modified: Sat Aug 06 17:12:03 GMT 2022 - 8.3K bytes - Viewed (0) -
guava-tests/test/com/google/common/cache/CacheBuilderSpecTest.java
* limitations under the License. */ package com.google.common.cache; import static com.google.common.cache.CacheBuilderSpec.parse; import static com.google.common.cache.TestingWeighers.constantWeigher; import static org.junit.Assert.assertThrows; import com.google.common.base.Suppliers; import com.google.common.cache.LocalCache.Strength; import com.google.common.testing.EqualsTester;
Java - Registered: Fri Apr 19 12:43:09 GMT 2024 - Last Modified: Wed Sep 06 17:04:31 GMT 2023 - 19.2K bytes - Viewed (0)