pub struct PooledClient<'a> { /* private fields */ }Expand description
A client borrowed from the connection pool.
The connection is automatically returned to the pool when dropped.
Implementations§
Methods from Deref<Target = ElectrumClient>§
Sourcepub async fn get_balance(&self, address: &str) -> Result<Balance>
pub async fn get_balance(&self, address: &str) -> Result<Balance>
Sourcepub async fn get_balance_scripthash(&self, scripthash: &str) -> Result<Balance>
pub async fn get_balance_scripthash(&self, scripthash: &str) -> Result<Balance>
Get balance using scripthash directly.
Sourcepub async fn get_balances_scripthash(
&self,
scripthashes: &[String],
) -> Result<Vec<Balance>>
pub async fn get_balances_scripthash( &self, scripthashes: &[String], ) -> Result<Vec<Balance>>
Get balances using scripthashes directly (batch).
Sourcepub async fn list_unspent_scripthash(
&self,
scripthash: &str,
) -> Result<Vec<Utxo>>
pub async fn list_unspent_scripthash( &self, scripthash: &str, ) -> Result<Vec<Utxo>>
List unspent outputs using scripthash directly.
Sourcepub async fn get_transaction(&self, txid: &str) -> Result<String>
pub async fn get_transaction(&self, txid: &str) -> Result<String>
Sourcepub async fn get_history_scripthash(
&self,
scripthash: &str,
) -> Result<Vec<TxHistory>>
pub async fn get_history_scripthash( &self, scripthash: &str, ) -> Result<Vec<TxHistory>>
Get transaction history using scripthash directly.
Sourcepub async fn server_version(&self) -> Result<ServerVersion>
pub async fn server_version(&self) -> Result<ServerVersion>
Get server version information.
Also performs protocol version negotiation.
Sourcepub async fn get_block_height(&self) -> Result<u64>
pub async fn get_block_height(&self) -> Result<u64>
Get the current block height.
Trait Implementations§
Source§impl<'a> Deref for PooledClient<'a>
impl<'a> Deref for PooledClient<'a>
Auto Trait Implementations§
impl<'a> !Freeze for PooledClient<'a>
impl<'a> !RefUnwindSafe for PooledClient<'a>
impl<'a> Send for PooledClient<'a>
impl<'a> Sync for PooledClient<'a>
impl<'a> Unpin for PooledClient<'a>
impl<'a> !UnwindSafe for PooledClient<'a>
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