Struct scrypto::prelude::Ed25519PrivateKey
source · pub struct Ed25519PrivateKey(SecretKey);
Tuple Fields§
§0: SecretKey
Implementations§
source§impl Ed25519PrivateKey
impl Ed25519PrivateKey
pub const LENGTH: usize = 32usize
pub fn public_key(&self) -> Ed25519PublicKey
pub fn sign(&self, msg_hash: &impl IsHash) -> Ed25519Signature
pub fn to_bytes(&self) -> Vec<u8> ⓘ
pub fn from_bytes(slice: &[u8]) -> Result<Ed25519PrivateKey, ()>
pub fn from_u64(n: u64) -> Result<Ed25519PrivateKey, ()>
Auto Trait Implementations§
impl RefUnwindSafe for Ed25519PrivateKey
impl Send for Ed25519PrivateKey
impl Sync for Ed25519PrivateKey
impl Unpin for Ed25519PrivateKey
impl UnwindSafe for Ed25519PrivateKey
Blanket Implementations§
§impl<U> As for U
impl<U> As for U
§fn as_<T>(self) -> Twhere
T: CastFrom<U>,
fn as_<T>(self) -> Twhere
T: CastFrom<U>,
Casts
self
to type T
. The semantics of numeric casting with the as
operator are followed, so <T as As>::as_::<U>
can be used in the same way as T as U
for numeric conversions. Read moresource§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