MCPcopy Index your code
hub / github.com/TanStack/db / has

Method has

packages/db/src/utils/btree.ts:189–191  ·  view source on GitHub ↗

* Returns true if the key exists in the B+ tree, false if not. * Use get() for best performance; use has() if you need to * distinguish between "undefined value" and "key not present". * @param key Key to detect * @description Computational complexity: O(log size)

(key: K)

Source from the content-addressed store, hash-verified

187 * @description Computational complexity: O(log size)
188 */
189 has(key: K): boolean {
190 return this.forRange(key, key, true, undefined) !== 0
191 }
192
193 /**
194 * Removes a single key-value pair from the B+ tree.

Callers 15

onChannelMessageMethod · 0.45
encodeTransportValueFunction · 0.45
onChannelMessageMethod · 0.45
constructorMethod · 0.45
tryGrantNextLockFunction · 0.45

Calls 1

forRangeMethod · 0.95

Tested by 13

constructorMethod · 0.36
tryGrantNextLockFunction · 0.36
getMethod · 0.36
createMockCollectionFunction · 0.36
verifyConsistencyFunction · 0.36
createIndexUsageTrackerFunction · 0.36