MCPcopy Create free account
hub / github.com/e2wugui/zeze / put

Method put

ZezeJava/ZezeJava/src/main/java/Zeze/History/ApplyTable.java:78–84  ·  view source on GitHub ↗
(@NotNull K key, @NotNull V value)

Source from the content-addressed store, hash-verified

76 }
77
78 public void put(@NotNull K key, @NotNull V value) throws Exception {
79 var bbKey = originTable.encodeKey(key);
80 var bbValue = ByteBuffer.Allocate();
81 value.encode(bbValue);
82 lru.put(key, value);
83 table.put(bbKey.Bytes, bbKey.ReadIndex, bbKey.size(), bbValue.Bytes, bbValue.ReadIndex, bbValue.size());
84 }
85
86 public void remove(@NotNull K key) throws Exception {
87 lru.remove(key);

Callers 1

applyMethod · 0.95

Calls 5

AllocateMethod · 0.95
encodeKeyMethod · 0.65
encodeMethod · 0.65
putMethod · 0.65
sizeMethod · 0.65

Tested by

no test coverage detected