MCPcopy
hub / github.com/clientIO/joint / delete

Method delete

packages/joint-core/src/alg/Deque.mjs:99–110  ·  view source on GitHub ↗
(key)

Source from the content-addressed store, hash-verified

97
98 // Remove a node from the deque
99 delete(key) {
100 const node = this.map.get(key);
101 if (!node) return;
102
103 if (node.prev) node.prev.next = node.next;
104 else this.head = node.next;
105
106 if (node.next) node.next.prev = node.prev;
107 else this.tail = node.prev;
108
109 this.map.delete(key);
110 }
111
112 // Does the deque contain a node with the given key?
113 has(key) {

Callers 8

subscribeHandlerFunction · 0.45
diffUpdateFunction · 0.45
setMeasuredNodeFunction · 0.45
utilHelpers.jsFile · 0.45
popHeadMethod · 0.45
Collection.mjsFile · 0.45
removeMethod · 0.45
Paper.mjsFile · 0.45

Calls 1

getMethod · 0.45

Tested by

no test coverage detected