logo
pub trait AddressValidator: Send + Sync + Debug {
    fn validate(
        &self,
        keychain: KeychainKind,
        hd_keypaths: &HdKeyPaths,
        script: &Script
    ) -> Result<(), AddressValidatorError>; }
👎 Deprecated:

AddressValidator was rarely used. Address validation can occur outside of BDK

Expand description

Trait to build address validators

All the address validators attached to a wallet with Wallet::add_address_validator will be polled every time an address (external or internal) is generated by the wallet. Errors returned in the validator will be propagated up to the original caller that triggered the address generation.

For a usage example see this module’s documentation.

Required Methods

👎 Deprecated:

AddressValidator was rarely used. Address validation can occur outside of BDK

Validate or inspect an address

Implementors