MCPcopy Create free account
hub / github.com/Berkeley-CS61B/skeleton-sp23 / put

Method put

lab07/src/Map61B.java:13–13  ·  view source on GitHub ↗

Associates the specified value with the specified key in this map. If the map already contains the specified key, replaces the key's mapping with the value specified.

(K key, V value)

Source from the content-addressed store, hash-verified

11 * If the map already contains the specified key, replaces the key's mapping
12 * with the value specified. */
13 void put(K key, V value);
14
15 /** Returns the value to which the specified key is mapped, or null if this
16 * map contains no mapping for the key. */

Callers 15

testFromSpecMethod · 0.65
handleMethod · 0.65
insertRandomMethod · 0.65
insertInOrderMethod · 0.65
insertRandomMethod · 0.65
testRemoveMethod · 0.65
testRemoveThreeCasesMethod · 0.65
sanityKeySetTestMethod · 0.65
sanityClearTestMethod · 0.65
containsKeyTestMethod · 0.65
sanityGetTestMethod · 0.65
sanitySizeTestMethod · 0.65

Implementers 2

ULLMaplab08/src/hashmap/ULLMap.java
ULLMaplab07/src/ULLMap.java

Calls

no outgoing calls

Tested by 15

testFromSpecMethod · 0.52
insertRandomMethod · 0.52
insertInOrderMethod · 0.52
insertRandomMethod · 0.52
testRemoveMethod · 0.52
testRemoveThreeCasesMethod · 0.52
sanityKeySetTestMethod · 0.52
sanityClearTestMethod · 0.52
containsKeyTestMethod · 0.52
sanityGetTestMethod · 0.52
sanitySizeTestMethod · 0.52
sanityPutTestMethod · 0.52