pub struct EthereumKeypair {
pub secret_key: SecretKey,
pub public_key: PublicKey,
pub address: EthereumAddress,
}Fields§
§secret_key: SecretKey§public_key: PublicKey§address: EthereumAddressImplementations§
Source§impl EthereumKeypair
impl EthereumKeypair
pub fn from_secret_key_str(private_key: &str) -> Result<Self, Error>
pub fn from_secret_key(x: &[u8]) -> Result<Self, Error>
pub fn generate_new<T: Rng + ?Sized>(rng_core: &mut T) -> Self
pub fn generate_new_with_thread_rng() -> Self
pub fn get_address(&self) -> &EthereumAddress
pub fn get_secret_key(&self) -> &SecretKey
pub fn get_public_key(&self) -> &PublicKey
pub fn export_secret_key_as_hex_string(&self) -> String
pub fn export_public_key_as_hex_string(&self) -> String
Auto Trait Implementations§
impl Freeze for EthereumKeypair
impl RefUnwindSafe for EthereumKeypair
impl Send for EthereumKeypair
impl Sync for EthereumKeypair
impl Unpin for EthereumKeypair
impl UnwindSafe for EthereumKeypair
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