Struct jujutsu_lib::index::ReadonlyIndex
source · pub struct ReadonlyIndex { /* private fields */ }Implementations§
source§impl ReadonlyIndex
impl ReadonlyIndex
pub fn as_index_ref(self: &ReadonlyIndex) -> IndexRef<'_>
pub fn num_commits(&self) -> u32
pub fn name(&self) -> &str
pub fn stats(&self) -> IndexStats
pub fn commit_id_to_pos(&self, commit_id: &CommitId) -> Option<IndexPosition>
pub fn resolve_prefix(&self, prefix: &HexPrefix) -> PrefixResolution<CommitId>
pub fn entry_by_id(&self, commit_id: &CommitId) -> Option<IndexEntry<'_>>
pub fn entry_by_pos(&self, pos: IndexPosition) -> IndexEntry<'_>
pub fn has_id(&self, commit_id: &CommitId) -> bool
pub fn is_ancestor(
&self,
ancestor_id: &CommitId,
descendant_id: &CommitId
) -> bool
pub fn common_ancestors(
&self,
set1: &[CommitId],
set2: &[CommitId]
) -> Vec<CommitId> ⓘ
pub fn walk_revs(&self, wanted: &[CommitId], unwanted: &[CommitId]) -> RevWalk<'_> ⓘ
pub fn heads<'candidates>(
&self,
candidates: impl IntoIterator<Item = &'candidates CommitId>
) -> Vec<CommitId> ⓘ
pub fn topo_order<'candidates>(
&self,
input: impl IntoIterator<Item = &'candidates CommitId>
) -> Vec<IndexEntry<'_>> ⓘ
Trait Implementations§
source§impl Debug for ReadonlyIndex
impl Debug for ReadonlyIndex
source§impl<'a> From<&'a ReadonlyIndex> for IndexRef<'a>
impl<'a> From<&'a ReadonlyIndex> for IndexRef<'a>
source§fn from(index: &'a ReadonlyIndex) -> Self
fn from(index: &'a ReadonlyIndex) -> Self
Converts to this type from the input type.