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

Method list_leaves

atomic-core/src/crdt/apply/leaf.rs:602–608  ·  view source on GitHub ↗
(&self, branch_id: BranchId)

Source from the content-addressed store, hash-verified

600 }
601
602 fn list_leaves(&self, branch_id: BranchId) -> Result<Vec<LeafId>, Self::Error> {
603 Ok(self
604 .branch_leaves
605 .get(&branch_id)
606 .cloned()
607 .unwrap_or_default())
608 }
609
610 fn count_leaves(&self, branch_id: BranchId) -> Result<usize, Self::Error> {
611 Ok(self.branch_leaves.get(&branch_id).map_or(0, |v| v.len()))

Callers

nothing calls this directly

Calls 1

getMethod · 0.65

Tested by

no test coverage detected