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

Method makeComputingMap

corpus/java/training/guava/collect/MapMaker.java:345–348  ·  view source on GitHub ↗

Builds a map that supports atomic, on-demand computation of values. Map#get either returns an already-computed value for the given key, atomically computes it using the supplied function, or, if another thread is currently computing the value for this key, simply waits for that thread to fin

(Function<? super K, ? extends V> computingFunction)

Source from the content-addressed store, hash-verified

343 * Guide</a> for more details.
344 */
345 @Deprecated
346 <K, V> ConcurrentMap<K, V> makeComputingMap(Function<? super K, ? extends V> computingFunction) {
347 return new MapMaker.ComputingMapAdapter<K, V>(this, computingFunction);
348 }
349
350 /**
351 * Returns a string representation for this MapMaker instance. The exact form of the returned

Callers 2

readObjectMethod · 0.95
ArbitraryOrderingClass · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected