pub struct Signer { /* private fields */ }
Expand description
A Software signer, wrapper over lwk_signer::SwSigner
Implementations§
source§impl Signer
impl Signer
sourcepub fn new(
mnemonic: &Mnemonic,
network: &Network
) -> Result<Arc<Self>, LwkError>
pub fn new( mnemonic: &Mnemonic, network: &Network ) -> Result<Arc<Self>, LwkError>
Construct a software signer
sourcepub fn sign(&self, pset: &Pset) -> Result<Arc<Pset>, LwkError>
pub fn sign(&self, pset: &Pset) -> Result<Arc<Pset>, LwkError>
Sign the given pset
Note from an API perspective it would be better to consume the pset
parameter so it would
be clear the signed PSET is the returned one, but it’s not possible with uniffi bindings
pub fn wpkh_slip77_descriptor(&self) -> Result<Arc<WolletDescriptor>, LwkError>
Trait Implementations§
source§impl<T> LowerReturn<T> for Signer
impl<T> LowerReturn<T> for Signer
§type ReturnType = <Signer as FfiConverterArc<UniFfiTag>>::FfiType
type ReturnType = <Signer as FfiConverterArc<UniFfiTag>>::FfiType
The type that should be returned by scaffolding functions for this type. Read more
source§fn lower_return(obj: Self) -> Result<Self::ReturnType, RustBuffer>
fn lower_return(obj: Self) -> Result<Self::ReturnType, RustBuffer>
Lower this value for scaffolding function return Read more
const TYPE_ID_META: MetadataBuffer = _
Auto Trait Implementations§
impl Freeze for Signer
impl RefUnwindSafe for Signer
impl Send for Signer
impl Sync for Signer
impl Unpin for Signer
impl UnwindSafe for Signer
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
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§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