Trait gix::prelude::FindExt

source ·
pub trait FindExt: Find {
    // Provided methods
    fn find<'a>(
        &self,
        id: &oid,
        buffer: &'a mut Vec<u8, Global>
    ) -> Result<Data<'a>, Error> { ... }
    fn find_commit<'a>(
        &self,
        id: &oid,
        buffer: &'a mut Vec<u8, Global>
    ) -> Result<CommitRef<'a>, Error> { ... }
    fn find_tree<'a>(
        &self,
        id: &oid,
        buffer: &'a mut Vec<u8, Global>
    ) -> Result<TreeRef<'a>, Error> { ... }
    fn find_tag<'a>(
        &self,
        id: &oid,
        buffer: &'a mut Vec<u8, Global>
    ) -> Result<TagRef<'a>, Error> { ... }
    fn find_blob<'a>(
        &self,
        id: &oid,
        buffer: &'a mut Vec<u8, Global>
    ) -> Result<BlobRef<'a>, Error> { ... }
    fn find_commit_iter<'a>(
        &self,
        id: &oid,
        buffer: &'a mut Vec<u8, Global>
    ) -> Result<CommitRefIter<'a>, Error> { ... }
    fn find_tree_iter<'a>(
        &self,
        id: &oid,
        buffer: &'a mut Vec<u8, Global>
    ) -> Result<TreeRefIter<'a>, Error> { ... }
    fn find_tag_iter<'a>(
        &self,
        id: &oid,
        buffer: &'a mut Vec<u8, Global>
    ) -> Result<TagRefIter<'a>, Error> { ... }
}
Expand description

An extension trait with convenience functions.

Provided Methods§

source

fn find<'a>( &self, id: &oid, buffer: &'a mut Vec<u8, Global> ) -> Result<Data<'a>, Error>

Like try_find(…), but flattens the Result<Option<_>> into a single Result making a non-existing object an error.

source

fn find_commit<'a>( &self, id: &oid, buffer: &'a mut Vec<u8, Global> ) -> Result<CommitRef<'a>, Error>

Like find(…), but flattens the Result<Option<_>> into a single Result making a non-existing object an error while returning the desired object type.

source

fn find_tree<'a>( &self, id: &oid, buffer: &'a mut Vec<u8, Global> ) -> Result<TreeRef<'a>, Error>

Like find(…), but flattens the Result<Option<_>> into a single Result making a non-existing object an error while returning the desired object type.

source

fn find_tag<'a>( &self, id: &oid, buffer: &'a mut Vec<u8, Global> ) -> Result<TagRef<'a>, Error>

Like find(…), but flattens the Result<Option<_>> into a single Result making a non-existing object an error while returning the desired object type.

source

fn find_blob<'a>( &self, id: &oid, buffer: &'a mut Vec<u8, Global> ) -> Result<BlobRef<'a>, Error>

Like find(…), but flattens the Result<Option<_>> into a single Result making a non-existing object an error while returning the desired object type.

source

fn find_commit_iter<'a>( &self, id: &oid, buffer: &'a mut Vec<u8, Global> ) -> Result<CommitRefIter<'a>, Error>

Like find(…), but flattens the Result<Option<_>> into a single Result making a non-existing object an error while returning the desired iterator type.

source

fn find_tree_iter<'a>( &self, id: &oid, buffer: &'a mut Vec<u8, Global> ) -> Result<TreeRefIter<'a>, Error>

Like find(…), but flattens the Result<Option<_>> into a single Result making a non-existing object an error while returning the desired iterator type.

source

fn find_tag_iter<'a>( &self, id: &oid, buffer: &'a mut Vec<u8, Global> ) -> Result<TagRefIter<'a>, Error>

Like find(…), but flattens the Result<Option<_>> into a single Result making a non-existing object an error while returning the desired iterator type.

Implementors§

source§

impl<T> FindExt for Twhere T: Find,