[][src]Struct pgp::types::Mpi

pub struct Mpi(_);

Represents an owned MPI value. The inner value is ready to be serialized, without the need to strip leading zeros.

Methods

impl Mpi[src]

pub fn from_raw(v: Vec<u8>) -> Self[src]

pub fn from_slice(slice: &[u8]) -> Self[src]

pub fn from_raw_slice(raw: &[u8]) -> Self[src]

Strips leading zeros.

pub fn as_ref(&self) -> MpiRef[src]

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

Trait Implementations

impl Serialize for Mpi[src]

impl AsRef<[u8]> for Mpi[src]

impl<'_> From<&'_ [u8]> for Mpi[src]

impl From<Vec<u8>> for Mpi[src]

impl From<BigUint> for Mpi[src]

impl From<Mpi> for BigUint[src]

impl<'a> From<&'a Mpi> for BigUint[src]

impl<'a> From<&'a BigUint> for Mpi[src]

impl Clone for Mpi[src]

impl Default for Mpi[src]

impl Eq for Mpi[src]

impl PartialEq<Mpi> for Mpi[src]

impl Debug for Mpi[src]

impl Deref for Mpi[src]

type Target = [u8]

The resulting type after dereferencing.

impl Zeroize for Mpi[src]

Auto Trait Implementations

impl Send for Mpi

impl Sync for Mpi

impl Unpin for Mpi

impl UnwindSafe for Mpi

impl RefUnwindSafe for Mpi

Blanket Implementations

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

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

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

type Owned = T

The resulting type after obtaining ownership.

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<T> Borrow<T> for T where
    T: ?Sized
[src]

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

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

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> Clear for T where
    T: InitializableFromZeroed + ?Sized
[src]

impl<T> InitializableFromZeroed for T where
    T: Default
[src]

impl<Z> Zeroize for Z where
    Z: DefaultIsZeroes
[src]

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

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

impl<T> ToHex for T where
    T: AsRef<[u8]>, 
[src]