[][src]Struct sequoia_openpgp::packet::MDC

pub struct MDC { /* fields omitted */ }

Holds an MDC packet.

A modification detection code packet. This packet appears after a SEIP packet. See Section 5.14 of RFC 4880 for details.


impl MDC[src]

pub fn new(digest: [u8; 20], computed_digest: [u8; 20]) -> Self[src]

Creates an MDC packet.

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

Gets the packet's hash value.

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

Gets the computed hash value.

pub fn valid(&self) -> bool[src]

Returns whether the data protected by the MDC is valid.

Trait Implementations

impl Clone for MDC[src]

impl Debug for MDC[src]

impl Eq for MDC[src]

impl From<[u8; 20]> for MDC[src]

impl From<Context> for MDC[src]

impl From<MDC> for Packet[src]

impl Hash for MDC[src]

impl<'a> Parse<'a, MDC> for MDC[src]

impl PartialEq<MDC> for MDC[src]

impl Serialize for MDC[src]

impl SerializeInto for MDC[src]

Auto Trait Implementations

impl RefUnwindSafe for MDC

impl Send for MDC

impl Sync for MDC

impl Unpin for MDC

impl UnwindSafe for MDC

Blanket Implementations

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

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

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

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

impl<T, U> Into<U> for T where
    U: From<T>, 

impl<T> ToOwned for T where
    T: Clone

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 

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