Struct diem_sdk::crypto::ed25519::Ed25519PublicKey [−][src]
pub struct Ed25519PublicKey(_);Expand description
An Ed25519 public key
Implementations
Trait Implementations
type Parameters = ()
type Parameters = ()
The type of parameters that arbitrary_with accepts for configuration
of the generated Strategy. Parameters must implement Default. Read more
type Strategy = BoxedStrategy<Ed25519PublicKey>
type Strategy = BoxedStrategy<Ed25519PublicKey>
pub fn arbitrary_with(
_args: <Ed25519PublicKey as Arbitrary>::Parameters
) -> <Ed25519PublicKey as Arbitrary>::Strategy
pub fn arbitrary_with(
_args: <Ed25519PublicKey as Arbitrary>::Parameters
) -> <Ed25519PublicKey as Arbitrary>::Strategy
pub fn deserialize<D>(
deserializer: D
) -> Result<Ed25519PublicKey, <D as Deserializer<'de>>::Error> where
D: Deserializer<'de>,
pub fn deserialize<D>(
deserializer: D
) -> Result<Ed25519PublicKey, <D as Deserializer<'de>>::Error> where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Performs the conversion.
Convenient method to create a MultiEd25519PublicKey from a single Ed25519PublicKey.
Performs the conversion.
We require public / private types to be coupled, i.e. their associated type is each other. Read more
pub fn serialize<S>(
&self,
serializer: S
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error> where
S: Serializer,
pub fn serialize<S>(
&self,
serializer: S
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error> where
S: Serializer,
Serialize this value into the given Serde serializer. Read more
Deserialize an Ed25519PublicKey. This method will also check for key validity, for instance it will only deserialize keys that are safe against small subgroup attacks.
type Error = CryptoMaterialError
type Error = CryptoMaterialError
The type returned in the event of a conversion error.
The unvalidated form of some type V
pub fn validate(
unvalidated: &<Ed25519PublicKey as Validate>::Unvalidated
) -> Result<Ed25519PublicKey, Error>
pub fn validate(
unvalidated: &<Ed25519PublicKey as Validate>::Unvalidated
) -> Result<Ed25519PublicKey, Error>
Attempt to validate a V::Unvalidated and returning a validated V on success
Return the unvalidated form of type V
The associated signing key type for this verifying key.
The associated signature type for this verifying key.
fn verify_struct_signature<T>(
&self,
message: &T,
signature: &Self::SignatureMaterial
) -> Result<(), Error> where
T: CryptoHash + Serialize,
fn verify_struct_signature<T>(
&self,
message: &T,
signature: &Self::SignatureMaterial
) -> Result<(), Error> where
T: CryptoHash + Serialize,
We provide the striaghtfoward implementation which dispatches to the signature.
fn batch_verify<T>(
message: &T,
keys_and_signatures: Vec<(Self, Self::SignatureMaterial), Global>
) -> Result<(), Error> where
T: CryptoHash + Serialize,
fn batch_verify<T>(
message: &T,
keys_and_signatures: Vec<(Self, Self::SignatureMaterial), Global>
) -> Result<(), Error> where
T: CryptoHash + Serialize,
We provide the implementation which dispatches to the signature.
Auto Trait Implementations
impl RefUnwindSafe for Ed25519PublicKey
impl Send for Ed25519PublicKey
impl Sync for Ed25519PublicKey
impl Unpin for Ed25519PublicKey
impl UnwindSafe for Ed25519PublicKey
Blanket Implementations
Mutably borrows from an owned value. Read more
Compare self to key and return true if they are equal.
Instruments this type with the provided Span, returning an
Instrumented wrapper. Read more
type Output = T
type Output = T
Should always be Self
Generates a hash used only for tests.
pub fn vzip(self) -> V
When trying to convert from bytes, we simply decode the string into bytes before checking if we can convert. Read more
A function to encode into hex-string after serializing.