[][src]Enum yamf_hash::YamfHash

pub enum YamfHash<T: Borrow<[u8]>> {
    Blake2b(T),
}

Variants of YamfHash

Variants

Blake2b(T)

Implementations

impl<T: Borrow<[u8]>> YamfHash<T>[src]

pub fn encode(&self, out: &mut [u8]) -> Result<usize, Error>[src]

Encode a YamfHash into the out buffer.

pub fn encoding_length(&self) -> usize[src]

pub fn decode<'a>(
    bytes: &'a [u8]
) -> Result<(YamfHash<&'a [u8]>, &'a [u8]), Error>
[src]

Decode the bytes as a YamfHash

pub fn decode_owned<'a>(
    bytes: &'a [u8]
) -> Result<(YamfHash<ArrayVec<[u8; 64]>>, &'a [u8]), Error>
[src]

Decode the bytes as a YamfHash

pub fn encode_write<W: Write>(&self, w: W) -> Result<(), Error>[src]

Encode a YamfHash into the writer.

Trait Implementations

impl<T: Debug + Borrow<[u8]>> Debug for YamfHash<T>[src]

impl<'de, T: Borrow<[u8]>> Deserialize<'de> for YamfHash<T> where
    T: From<Vec<u8>>, 
[src]

impl<T: Eq + Borrow<[u8]>> Eq for YamfHash<T>[src]

impl<'a> From<&'a YamfHash<ArrayVec<[u8; 64]>>> for YamfHash<&'a [u8]>[src]

impl<'a> From<Hash> for YamfHash<ArrayVec<[u8; 64]>>[src]

impl<B1: Borrow<[u8]>, B2: Borrow<[u8]>> PartialEq<YamfHash<B1>> for YamfHash<B2>[src]

impl<T: Borrow<[u8]>> Serialize for YamfHash<T>[src]

impl<T: Borrow<[u8]>> StructuralEq for YamfHash<T>[src]

Auto Trait Implementations

impl<T> RefUnwindSafe for YamfHash<T> where
    T: RefUnwindSafe
[src]

impl<T> Send for YamfHash<T> where
    T: Send
[src]

impl<T> Sync for YamfHash<T> where
    T: Sync
[src]

impl<T> Unpin for YamfHash<T> where
    T: Unpin
[src]

impl<T> UnwindSafe for YamfHash<T> where
    T: UnwindSafe
[src]

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, 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.