Skip to main content

Signer

Trait Signer 

Source
pub trait Signer<N: Network>: MessageSigner {
    // Required method
    fn sign_transaction_from(
        &self,
        sender: &Address,
        tx: N::UnsignedTx,
    ) -> Result<N::TxEnvelope, BlockchainError>;
}
Expand description

A transaction signer, generic over the network.

Modelled after alloy’s NetworkWallet<N>: the sign_transaction_from method takes an unsigned transaction and returns the fully-signed envelope in one step.

Required Methods§

Source

fn sign_transaction_from( &self, sender: &Address, tx: N::UnsignedTx, ) -> Result<N::TxEnvelope, BlockchainError>

Signs an unsigned transaction and returns the signed envelope.

Mirrors NetworkWallet::sign_transaction_from.

Implementors§

Source§

impl Signer<FoundryNetwork> for DevSigner