[−][src]Struct veriform::decoder::Decoder
Veriform decoder.
This type contains message decoding state and also performs Verihash computation.
It's intended to be used in conjunction with the Message
trait.
Implementations
impl<D> Decoder<D> where
D: Digest,
[src]
D: Digest,
pub fn new() -> Self
[src]
Initialize decoder
pub fn fill_digest(&mut self, output: &mut [u8]) -> Result<(), Error>
[src]
Fill the provided slice with the digest of the message if it fits
Trait Implementations
impl<D, M> Decode<M> for Decoder<D> where
D: Digest,
M: Message,
[src]
D: Digest,
M: Message,
impl<D> Decode<i64> for Decoder<D> where
D: Digest,
[src]
D: Digest,
impl<D> Decode<u64> for Decoder<D> where
D: Digest,
[src]
D: Digest,
impl<D> DecodeRef<[u8]> for Decoder<D> where
D: Digest,
[src]
D: Digest,
impl<D> DecodeRef<str> for Decoder<D> where
D: Digest,
[src]
D: Digest,
impl<D, M> DecodeSeq<M, D> for Decoder<D> where
D: Digest,
M: Message,
[src]
D: Digest,
M: Message,
fn decode_seq<'a, 'b>(
&'a mut self,
tag: Tag,
input: &mut &'b [u8]
) -> Result<Iter<'a, 'b, M, D>, Error>
[src]
&'a mut self,
tag: Tag,
input: &mut &'b [u8]
) -> Result<Iter<'a, 'b, M, D>, Error>
impl<D> DecodeSeq<i64, D> for Decoder<D> where
D: Digest,
[src]
D: Digest,
fn decode_seq<'a, 'b>(
&'a mut self,
tag: Tag,
input: &mut &'b [u8]
) -> Result<Iter<'a, 'b, i64, D>, Error>
[src]
&'a mut self,
tag: Tag,
input: &mut &'b [u8]
) -> Result<Iter<'a, 'b, i64, D>, Error>
impl<D> DecodeSeq<u64, D> for Decoder<D> where
D: Digest,
[src]
D: Digest,
fn decode_seq<'a, 'b>(
&'a mut self,
tag: Tag,
input: &mut &'b [u8]
) -> Result<Iter<'a, 'b, u64, D>, Error>
[src]
&'a mut self,
tag: Tag,
input: &mut &'b [u8]
) -> Result<Iter<'a, 'b, u64, D>, Error>
impl<D> Default for Decoder<D> where
D: Digest,
[src]
D: Digest,
Auto Trait Implementations
impl<D> RefUnwindSafe for Decoder<D> where
D: RefUnwindSafe,
<<D as Digest>::OutputSize as ArrayLength<u8>>::ArrayType: RefUnwindSafe,
D: RefUnwindSafe,
<<D as Digest>::OutputSize as ArrayLength<u8>>::ArrayType: RefUnwindSafe,
impl<D> Send for Decoder<D> where
D: Send,
<D as Digest>::OutputSize: ArrayLength<u8>,
D: Send,
<D as Digest>::OutputSize: ArrayLength<u8>,
impl<D> Sync for Decoder<D> where
D: Sync,
<D as Digest>::OutputSize: ArrayLength<u8>,
D: Sync,
<D as Digest>::OutputSize: ArrayLength<u8>,
impl<D> Unpin for Decoder<D> where
D: Unpin,
<<D as Digest>::OutputSize as ArrayLength<u8>>::ArrayType: Unpin,
D: Unpin,
<<D as Digest>::OutputSize as ArrayLength<u8>>::ArrayType: Unpin,
impl<D> UnwindSafe for Decoder<D> where
D: UnwindSafe,
<<D as Digest>::OutputSize as ArrayLength<u8>>::ArrayType: UnwindSafe,
D: UnwindSafe,
<<D as Digest>::OutputSize as ArrayLength<u8>>::ArrayType: UnwindSafe,
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,