Struct tor_interface::tor_crypto::X25519PublicKey
source · pub struct X25519PublicKey { /* private fields */ }
Implementations§
source§impl X25519PublicKey
impl X25519PublicKey
pub fn from_private_key(private_key: &X25519PrivateKey) -> X25519PublicKey
pub fn from_raw(raw: &[u8; 32]) -> X25519PublicKey
pub fn from_base32(base32: &str) -> Result<X25519PublicKey, Error>
pub fn to_base32(&self) -> String
pub fn as_bytes(&self) -> &[u8; 32]
Trait Implementations§
source§impl Clone for X25519PublicKey
impl Clone for X25519PublicKey
source§fn clone(&self) -> X25519PublicKey
fn clone(&self) -> X25519PublicKey
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for X25519PublicKey
impl Debug for X25519PublicKey
source§impl Hash for X25519PublicKey
impl Hash for X25519PublicKey
source§impl PartialEq for X25519PublicKey
impl PartialEq for X25519PublicKey
source§fn eq(&self, other: &X25519PublicKey) -> bool
fn eq(&self, other: &X25519PublicKey) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for X25519PublicKey
impl StructuralPartialEq for X25519PublicKey
Auto Trait Implementations§
impl Freeze for X25519PublicKey
impl RefUnwindSafe for X25519PublicKey
impl Send for X25519PublicKey
impl Sync for X25519PublicKey
impl Unpin for X25519PublicKey
impl UnwindSafe for X25519PublicKey
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§impl<Source, Target> OctetsInto<Target> for Sourcewhere
Target: OctetsFrom<Source>,
impl<Source, Target> OctetsInto<Target> for Sourcewhere
Target: OctetsFrom<Source>,
type Error = <Target as OctetsFrom<Source>>::Error
source§fn try_octets_into(
self,
) -> Result<Target, <Source as OctetsInto<Target>>::Error>
fn try_octets_into( self, ) -> Result<Target, <Source as OctetsInto<Target>>::Error>
Performs the conversion.
source§fn octets_into(self) -> Target
fn octets_into(self) -> Target
Performs an infallible conversion.