Struct ed25519_consensus::SigningKey
source · [−]pub struct SigningKey { /* private fields */ }
Expand description
An Ed25519 signing key.
This is also called a secret key by other implementations.
Implementations
sourceimpl SigningKey
impl SigningKey
sourcepub fn to_bytes(&self) -> [u8; 32]
pub fn to_bytes(&self) -> [u8; 32]
Returns the byte encoding of the signing key.
This is the same as .into()
, but does not require type inference.
sourcepub fn verification_key(&self) -> VerificationKey
pub fn verification_key(&self) -> VerificationKey
Obtain the verification key associated with this signing key.
Trait Implementations
sourceimpl Clone for SigningKey
impl Clone for SigningKey
sourcefn clone(&self) -> SigningKey
fn clone(&self) -> SigningKey
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for SigningKey
impl Debug for SigningKey
sourceimpl<'de> Deserialize<'de> for SigningKey
impl<'de> Deserialize<'de> for SigningKey
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl<'a> From<&'a SigningKey> for VerificationKey
impl<'a> From<&'a SigningKey> for VerificationKey
sourcefn from(sk: &'a SigningKey) -> VerificationKey
fn from(sk: &'a SigningKey) -> VerificationKey
Converts to this type from the input type.
sourceimpl<'a> From<&'a SigningKey> for VerificationKeyBytes
impl<'a> From<&'a SigningKey> for VerificationKeyBytes
sourcefn from(sk: &'a SigningKey) -> VerificationKeyBytes
fn from(sk: &'a SigningKey) -> VerificationKeyBytes
Converts to this type from the input type.
sourceimpl Serialize for SigningKey
impl Serialize for SigningKey
Auto Trait Implementations
impl RefUnwindSafe for SigningKey
impl Send for SigningKey
impl Sync for SigningKey
impl Unpin for SigningKey
impl UnwindSafe for SigningKey
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToHex for T where
T: AsRef<[u8]>,
impl<T> ToHex for T where
T: AsRef<[u8]>,
sourcefn encode_hex<U>(&self) -> U where
U: FromIterator<char>,
fn encode_hex<U>(&self) -> U where
U: FromIterator<char>,
Encode the hex strict representing self
into the result. Lower case
letters are used (e.g. f9b4ca
) Read more
sourcefn encode_hex_upper<U>(&self) -> U where
U: FromIterator<char>,
fn encode_hex_upper<U>(&self) -> U where
U: FromIterator<char>,
Encode the hex strict representing self
into the result. Upper case
letters are used (e.g. F9B4CA
) Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more