MCPcopy Create free account
hub / github.com/antlr/codebuff / loadSync

Method loadSync

output/java_guava/1.4.13/LocalCache.java:2387–2394  ·  view source on GitHub ↗
(
        K key,
        int hash,
        LoadingValueReference<K, V> loadingValueReference,
        CacheLoader<? super K, V> loader)

Source from the content-addressed store, hash-verified

2385 // at most one of loadSync/loadAsync may be called for any given LoadingValueReference
2386
2387 V loadSync(
2388 K key,
2389 int hash,
2390 LoadingValueReference<K, V> loadingValueReference,
2391 CacheLoader<? super K, V> loader) throws ExecutionException {
2392 ListenableFuture<V> loadingFuture = loadingValueReference.loadFuture(key, loader);
2393 return getAndRecordStats(key, hash, loadingValueReference, loadingFuture);
2394 }
2395
2396 ListenableFuture<V> loadAsync(final K key, final int hash, final LoadingValueReference<K, V> loadingValueReference, CacheLoader<? super K, V> loader) {
2397 final ListenableFuture<V> loadingFuture = loadingValueReference.loadFuture(key, loader);

Callers 1

lockedGetOrLoadMethod · 0.95

Calls 2

getAndRecordStatsMethod · 0.95
loadFutureMethod · 0.45

Tested by

no test coverage detected