pub struct OptionalNonZeroElGamalPubkey(/* private fields */);Expand description
An ElGamalPubkey that encodes None as all 0, meant to be usable as a
Pod type.
Implementations§
Source§impl OptionalNonZeroElGamalPubkey
impl OptionalNonZeroElGamalPubkey
Sourcepub fn equals(&self, other: &PodElGamalPubkey) -> bool
pub fn equals(&self, other: &PodElGamalPubkey) -> bool
Checks equality between an OptionalNonZeroElGamalPubkey and an
ElGamalPubkey when interpreted as bytes.
Trait Implementations§
Source§impl Clone for OptionalNonZeroElGamalPubkey
impl Clone for OptionalNonZeroElGamalPubkey
Source§fn clone(&self) -> OptionalNonZeroElGamalPubkey
fn clone(&self) -> OptionalNonZeroElGamalPubkey
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 OptionalNonZeroElGamalPubkey
impl Debug for OptionalNonZeroElGamalPubkey
Source§impl Default for OptionalNonZeroElGamalPubkey
impl Default for OptionalNonZeroElGamalPubkey
Source§fn default() -> OptionalNonZeroElGamalPubkey
fn default() -> OptionalNonZeroElGamalPubkey
Returns the “default value” for a type. Read more
Source§impl From<OptionalNonZeroElGamalPubkey> for Option<PodElGamalPubkey>
impl From<OptionalNonZeroElGamalPubkey> for Option<PodElGamalPubkey>
Source§fn from(p: OptionalNonZeroElGamalPubkey) -> Self
fn from(p: OptionalNonZeroElGamalPubkey) -> Self
Converts to this type from the input type.
Source§impl PartialEq for OptionalNonZeroElGamalPubkey
impl PartialEq for OptionalNonZeroElGamalPubkey
Source§fn eq(&self, other: &OptionalNonZeroElGamalPubkey) -> bool
fn eq(&self, other: &OptionalNonZeroElGamalPubkey) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Copy for OptionalNonZeroElGamalPubkey
impl Pod for OptionalNonZeroElGamalPubkey
impl StructuralPartialEq for OptionalNonZeroElGamalPubkey
Auto Trait Implementations§
impl Freeze for OptionalNonZeroElGamalPubkey
impl RefUnwindSafe for OptionalNonZeroElGamalPubkey
impl Send for OptionalNonZeroElGamalPubkey
impl Sync for OptionalNonZeroElGamalPubkey
impl Unpin for OptionalNonZeroElGamalPubkey
impl UnwindSafe for OptionalNonZeroElGamalPubkey
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> CheckedBitPattern for Twhere
T: AnyBitPattern,
impl<T> CheckedBitPattern for Twhere
T: AnyBitPattern,
Source§type Bits = T
type Bits = T
Self must have the same layout as the specified Bits except for
the possible invalid bit patterns being checked during
is_valid_bit_pattern.Source§fn is_valid_bit_pattern(_bits: &T) -> bool
fn is_valid_bit_pattern(_bits: &T) -> bool
If this function returns true, then it must be valid to reinterpret
bits
as &Self.Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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 more