Struct git_odb::linked::Db[][src]

pub struct Db {
    pub dbs: Vec<Db>,
}

A database with a list of compound databases created by traversing git alternates files.

It does not contain any objects itself.

Fields

dbs: Vec<Db>

The compound databases containing the actual objects.

Implementations

impl Db[src]

pub fn at(objects_directory: impl Into<PathBuf>) -> Result<Self, Error>[src]

Instantiate an instance at the given objects_directory, commonly .git/objects.

git alternate files will be traversed to build a chain of compound::Db instances.

impl Db[src]

pub fn iter(&self) -> AllObjects<&Db>[src]

Return an iterator over all objects in all linked databases, database after database, first packed objects with the ‘best’ packs first, followed by loose objects. For specialized iterations, use the dbs fields directly as all databases are accessible.

pub fn arc_iter(self: &Arc<Db>) -> AllObjects<Arc<Db>>[src]

Like iter() but works with this instance living in an Arc

Useful in conjunction with 'static threads.

Trait Implementations

impl Locate for Db[src]

type Error = Error

The error returned by locate()

impl Locate for &Db[src]

type Error = Error

The error returned by locate()

impl TryFrom<PathBuf> for Db[src]

type Error = Error

The type returned in the event of a conversion error.

impl Write for Db[src]

type Error = Error

The error type used for all trait methods. Read more

Auto Trait Implementations

impl RefUnwindSafe for Db

impl Send for Db

impl Sync for Db

impl Unpin for Db

impl UnwindSafe for Db

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Conv for T

impl<T> Conv for T

impl<T> FmtForward for T

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Pipe for T where
    T: ?Sized

impl<T> Pipe for T

impl<T> PipeAsRef for T

impl<T> PipeBorrow for T

impl<T> PipeDeref for T

impl<T> PipeRef for T

impl<T> Pointable for T

type Init = T

The type for initializers.

impl<T> Tap for T

impl<T> Tap for T

impl<T, U> TapAsRef<U> for T where
    U: ?Sized

impl<T, U> TapBorrow<U> for T where
    U: ?Sized

impl<T> TapDeref for T

impl<T> TryConv for T

impl<T> TryConv for T

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,