MCPcopy Index your code
hub / github.com/antlr/codebuff / setValue

Method setValue

output/java_guava/1.4.13/AbstractBiMap.java:343–356  ·  view source on GitHub ↗
(V value)

Source from the content-addressed store, hash-verified

341 }
342
343 @Override
344 public V setValue(V value) {
345 // Preconditions keep the map and inverse consistent.
346 checkState(contains(this), "entry no longer in map");
347 // similar to putInBothMaps, but set via entry
348 if (Objects.equal(value, getValue())) {
349 return value;
350 }
351 checkArgument(!containsValue(value), "value already present: %s", value);
352 V oldValue = finalEntry.setValue(value);
353 checkState(Objects.equal(value, get(getKey())), "entry no longer in map");
354 updateInverseMap(getKey(), true, oldValue, value);
355 return oldValue;
356 }
357 };
358 }
359

Callers

nothing calls this directly

Calls 9

containsMethod · 0.95
equalMethod · 0.95
getValueMethod · 0.95
getMethod · 0.95
getKeyMethod · 0.95
containsValueMethod · 0.65
checkStateMethod · 0.45
checkArgumentMethod · 0.45
updateInverseMapMethod · 0.45

Tested by

no test coverage detected