Skip to main content

resolve_tree_path

Function resolve_tree_path 

Source
pub fn resolve_tree_path<S: ObjectSource>(
    store: &S,
    root: &ContentHash,
    path: &Path,
    policy: LeafPolicy,
) -> Result<Option<ResolvedTreeTarget>, TreePathResolveError>
Expand description

Walk path from root through nested subtrees and resolve the terminal entry according to policy.

Ok(None) means the path is absent or terminates at the wrong entry type for the policy. Store failures and missing subtrees are policy-dependent; see TreePathResolveError.