Trait bdk::blockchain::Blockchain
source · pub trait Blockchain: WalletSync + GetHeight + GetTx + GetBlockHash {
fn get_capabilities(&self) -> HashSet<Capability>;
fn broadcast(&self, tx: &Transaction) -> Result<(), Error>;
fn estimate_fee(&self, target: usize) -> Result<FeeRate, Error>;
}
Expand description
Trait that defines the actions that must be supported by a blockchain backend
Required Methods
sourcefn get_capabilities(&self) -> HashSet<Capability>
fn get_capabilities(&self) -> HashSet<Capability>
Return the set of Capability
supported by this backend
Implementations on Foreign Types
sourceimpl<T: Blockchain> Blockchain for Arc<T>
impl<T: Blockchain> Blockchain for Arc<T>
fn get_capabilities(&self) -> HashSet<Capability>
fn broadcast(&self, tx: &Transaction) -> Result<(), Error>
fn estimate_fee(&self, target: usize) -> Result<FeeRate, Error>
Implementors
impl Blockchain for AnyBlockchain
impl Blockchain for CompactFiltersBlockchain
Available on crate feature
compact_filters
only.impl Blockchain for ElectrumBlockchain
Available on crate feature
electrum
only.impl Blockchain for EsploraBlockchain
Available on crate feature
esplora
only.impl Blockchain for RpcBlockchain
Available on crate feature
rpc
only.