MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / del_tree

Method del_tree

atomic-core/src/pristine/txn/write/mod.rs:1410–1423  ·  view source on GitHub ↗
(&mut self, path: &str)

Source from the content-addressed store, hash-verified

1408 }
1409
1410 fn del_tree(&mut self, path: &str) -> PristineResult<Option<Inode>> {
1411 let inode = {
1412 let mut table = self.txn.open_table(TREE)?;
1413 let removed = table.remove(path)?;
1414 removed.map(|value| Inode::new(value.value()))
1415 };
1416
1417 if let Some(inode) = inode {
1418 let mut table = self.txn.open_table(REV_TREE)?;
1419 table.remove(inode.get())?;
1420 }
1421
1422 Ok(inode)
1423 }
1424
1425 fn put_file_index(
1426 &mut self,

Callers 10

test_tree_operationsFunction · 0.80
write_import_recordedMethod · 0.80
insert_changeMethod · 0.80
write_recordedMethod · 0.80
remove_from_treeFunction · 0.80
move_trackedFunction · 0.80

Calls 2

removeMethod · 0.65
getMethod · 0.65

Tested by 1

test_tree_operationsFunction · 0.64