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

Method build

output/java_guava/1.4.13/CacheBuilder.java:828–831  ·  view source on GitHub ↗

Builds a cache, which either returns an already-loaded value for a given key or atomically computes or retrieves it using the supplied CacheLoader. If another thread is currently loading the value for this key, simply waits for that thread to finish and returns its loaded value. Note that mu

(CacheLoader<? super K1, V1> loader)

Source from the content-addressed store, hash-verified

826
827
828 public <K1 extends K, V1 extends V> LoadingCache<K1, V1> build(CacheLoader<? super K1, V1> loader) {
829 checkWeightWithWeigher();
830 return new LocalCache.LocalLoadingCache<K1, V1>(this, loader);
831 }
832
833 /**
834 * Builds a cache which does not automatically load values when keys are requested.

Callers 3

CacheBuilderSpecClass · 0.45
readObjectMethod · 0.45
readObjectMethod · 0.45

Calls 2

checkNonLoadingCacheMethod · 0.95

Tested by

no test coverage detected