pub struct Keypair {
pub private_key: PrivateKey,
pub public_key: PublicKey,
}Expand description
It represents an Symbol asymmetric private/public encryption key.
Fields§
§private_key: PrivateKeyThe private half of this keypair.
public_key: PublicKeyThe public half of this keypair.
Trait Implementations§
Source§impl<'a> From<&'a PrivateKey> for Keypair
impl<'a> From<&'a PrivateKey> for Keypair
Source§fn from(sk: &'a PrivateKey) -> Self
fn from(sk: &'a PrivateKey) -> Self
Converts to this type from the input type.
Source§impl From<PrivateKey> for Keypair
impl From<PrivateKey> for Keypair
Source§fn from(sk: PrivateKey) -> Self
fn from(sk: PrivateKey) -> Self
Converts to this type from the input type.
Source§impl KeyPairSchema for Keypair
impl KeyPairSchema for Keypair
Source§fn from_bytes(bytes: &[u8]) -> Result<Self>
fn from_bytes(bytes: &[u8]) -> Result<Self>
Construct a Symbol Keypair from the bytes of a PublicKey and PrivateKey.
Source§fn from_private_key(pk: PrivateKey) -> Self
fn from_private_key(pk: PrivateKey) -> Self
type Crypto = CryptoSym
fn private_key(&self) -> PrivateKey
fn public_key(&self) -> PublicKey
fn from_null_private_key(pk: PublicKey) -> Self
impl Copy for Keypair
impl StructuralPartialEq for Keypair
Auto Trait Implementations§
impl Freeze for Keypair
impl RefUnwindSafe for Keypair
impl Send for Keypair
impl Sync for Keypair
impl Unpin for Keypair
impl UnwindSafe for Keypair
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