Struct tx_bakery::utils::key_wallet::KeyWallet
source · pub struct KeyWallet { /* private fields */ }
Expand description
Simple wallet reading the signing key(s) from disk
Implementations§
source§impl KeyWallet
impl KeyWallet
sourcepub async fn new(
payment_skey: impl AsRef<Path>,
staking_skey: Option<impl AsRef<Path>>
) -> Result<KeyWallet, KeyWalletError>
pub async fn new( payment_skey: impl AsRef<Path>, staking_skey: Option<impl AsRef<Path>> ) -> Result<KeyWallet, KeyWalletError>
Initialise a base wallet by reading the signinig keys into memory
sourcepub async fn new_enterprise(
payment_skey: impl AsRef<Path>
) -> Result<KeyWallet, KeyWalletError>
pub async fn new_enterprise( payment_skey: impl AsRef<Path> ) -> Result<KeyWallet, KeyWalletError>
Initialise an enterprise wallet by reading the signinig key into memory
Trait Implementations§
source§impl Wallet for KeyWallet
impl Wallet for KeyWallet
source§fn sign_transaction(&self, tx: &FixedTransaction) -> FixedTransaction
fn sign_transaction(&self, tx: &FixedTransaction) -> FixedTransaction
Signs a fully built transaction
source§fn get_change_pkh(&self) -> Ed25519PubKeyHash
fn get_change_pkh(&self) -> Ed25519PubKeyHash
Query the public key hash used by this wallet
source§fn get_change_addr(&self) -> Address
fn get_change_addr(&self) -> Address
Query the wallet address
Auto Trait Implementations§
impl Freeze for KeyWallet
impl RefUnwindSafe for KeyWallet
impl Send for KeyWallet
impl Sync for KeyWallet
impl Unpin for KeyWallet
impl UnwindSafe for KeyWallet
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more