MCPcopy
hub / github.com/ZToolsCenter/ZTools / dbGet

Method dbGet

src/main/api/shared/database.ts:416–430  ·  view source on GitHub ↗
(key: string)

Source from the content-addressed store, hash-verified

414 }
415
416 public dbGet(key: string): any {
417 try {
418 const docId = `ZTOOLS/${key}`
419 const doc = lmdbInstance.get(docId)
420
421 if (!doc) {
422 return null
423 }
424
425 return doc.data
426 } catch (error) {
427 console.error('[Database] dbGet 失败:', key, error)
428 return null
429 }
430 }
431
432 /**
433 * 计算字典序的下一个前缀(用于精确的范围查询)

Callers 15

setupIPCMethod · 0.95
buildThemeInfoMethod · 0.45
setupIPCMethod · 0.45
processRedirectMethod · 0.45
getSettingPluginPathMethod · 0.45
getUsageStatsMethod · 0.45
getAppsMethod · 0.45
preparePluginLaunchMethod · 0.45

Calls 1

getMethod · 0.65

Tested by

no test coverage detected