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

Method putIfAbsent

corpus/java/training/guava/cache/LocalCache.java:4267–4273  ·  view source on GitHub ↗
(K key, V value)

Source from the content-addressed store, hash-verified

4265 }
4266
4267 @Override
4268 public V putIfAbsent(K key, V value) {
4269 checkNotNull(key);
4270 checkNotNull(value);
4271 int hash = hash(key);
4272 return segmentFor(hash).put(key, hash, value, true);
4273 }
4274
4275 @Override
4276 public void putAll(Map<? extends K, ? extends V> m) {

Callers 1

registerMethod · 0.45

Calls 4

hashMethod · 0.95
segmentForMethod · 0.95
putMethod · 0.65
checkNotNullMethod · 0.45

Tested by

no test coverage detected