[][src]Struct git_object::borrowed::Id

pub struct Id<'a>(_);

A reference to a SHA1 identifying objects

Implementations

impl<'a> Id<'a>[src]

pub fn kind(&self) -> HashKind[src]

pub fn first_byte(&self) -> u8[src]

impl<'a> Id<'a>[src]

Sha1 specific methods

pub fn to_sha1_hex(&self) -> [u8; 40][src]

pub fn sha1(&self) -> &[u8; 20][src]

Trait Implementations

impl<'a> Clone for Id<'a>[src]

impl<'a> Copy for Id<'a>[src]

impl<'a> Debug for Id<'a>[src]

impl<'de: 'a, 'a> Deserialize<'de> for Id<'a>[src]

Manually created from a version that uses a slice, and we forcefully try to convert it into a borrowed array of the desired size Could be improved by fitting this into serde Unfortunately the serde::Deserialize derive wouldn't work for borrowed arrays.

impl<'_> Display for Id<'_>[src]

impl<'a> Eq for Id<'a>[src]

impl<'a> From<&'a [u8; 20]> for Id<'a>[src]

impl<'a> From<Id<'a>> for Id[src]

impl<'a> Hash for Id<'a>[src]

impl<'a> Ord for Id<'a>[src]

impl<'a> PartialEq<Id<'a>> for Id<'a>[src]

impl<'a> PartialOrd<Id<'a>> for Id<'a>[src]

impl<'a> Serialize for Id<'a>[src]

impl<'a> StructuralEq for Id<'a>[src]

impl<'a> StructuralPartialEq for Id<'a>[src]

impl<'a> TryFrom<&'a [u8]> for Id<'a>[src]

type Error = TryFromSliceError

The type returned in the event of a conversion error.

Auto Trait Implementations

impl<'a> RefUnwindSafe for Id<'a>

impl<'a> Send for Id<'a>

impl<'a> Sync for Id<'a>

impl<'a> Unpin for Id<'a>

impl<'a> UnwindSafe for Id<'a>

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> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

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

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

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

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.