[][src]Struct x25519_dalek::PublicKey

pub struct PublicKey(_);

A PublicKey is the corresponding public key converted from an EphemeralSecret or a StaticSecret key.

Methods

impl PublicKey[src]

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

View this public key as a byte array.

Trait Implementations

impl Clone for PublicKey[src]

impl Copy for PublicKey[src]

impl Debug for PublicKey[src]

impl<'a> From<&'a EphemeralSecret> for PublicKey[src]

fn from(secret: &'a EphemeralSecret) -> PublicKey[src]

Given an x25519 EphemeralSecret key, compute its corresponding PublicKey key.

impl<'a> From<&'a StaticSecret> for PublicKey[src]

fn from(secret: &'a StaticSecret) -> PublicKey[src]

Given an x25519 StaticSecret key, compute its corresponding PublicKey key.

impl From<[u8; 32]> for PublicKey[src]

fn from(bytes: [u8; 32]) -> PublicKey[src]

Given a byte array, construct a x25519 PublicKey.

Auto Trait Implementations

impl RefUnwindSafe for PublicKey

impl Send for PublicKey

impl Sync for PublicKey

impl Unpin for PublicKey

impl UnwindSafe for PublicKey

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> From<T> for T[src]

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

impl<T> Same<T> for T

type Output = T

Should always be Self

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 = !

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.