MCPcopy Create free account
hub / github.com/Macmod/godap / exportCacheToFile

Function exportCacheToFile

tui/explorer.go:125–136  ·  view source on GitHub ↗
(currentNode *tview.TreeNode, cache *EntryCache, fileSuffix string)

Source from the content-addressed store, hash-verified

123}
124
125func exportCacheToFile(currentNode *tview.TreeNode, cache *EntryCache, fileSuffix string) {
126 exportMap := make(map[string]any)
127 currentNode.Walk(func(node, parent *tview.TreeNode) bool {
128 if node.GetReference() != nil {
129 nodeDN := node.GetReference().(string)
130 exportMap[nodeDN], _ = cache.Get(nodeDN)
131 }
132 return true
133 })
134
135 writeDataExport(exportMap, fileSuffix, "tree_objects")
136}
137
138func openDeleteObjectForm(node *tview.TreeNode, done func()) {
139 currentFocus := app.GetFocus()

Callers 3

attrsPanelKeyHandlerFunction · 0.85
initSearchPageFunction · 0.85
treePanelKeyHandlerFunction · 0.85

Calls 2

writeDataExportFunction · 0.85
GetMethod · 0.80

Tested by

no test coverage detected