Skip to main content

Signer

Trait Signer 

Source
pub trait Signer: Send + Sync {
    // Required methods
    fn address(&self) -> &str;
    fn sign(
        &self,
        request: &SignRequest,
    ) -> Result<TxWitness, Box<dyn Error + Send + Sync>>;
}
Expand description

A signer capable of producing TRP witnesses.

Signers are address-aware and must return the address they correspond to.

Required Methods§

Source

fn address(&self) -> &str

Returns the address associated with this signer.

Source

fn sign( &self, request: &SignRequest, ) -> Result<TxWitness, Box<dyn Error + Send + Sync>>

Signs the transaction described by request.

Implementors§