[][src]Struct cashweb_bitcoin_client::BitcoinClient

pub struct BitcoinClient<C>(_);

Basic bitcoin client

Methods

impl BitcoinClient<HttpConnector>[src]

pub fn new(endpoint: String, username: String, password: String) -> Self[src]

impl<C> BitcoinClient<C> where
    C: Connect + Clone + Send + Sync + 'static, 
[src]

pub async fn get_new_addr<'_>(&'_ self) -> Result<String, NodeError>[src]

pub async fn send_tx<'_, '_>(
    &'_ self,
    raw_tx: &'_ [u8]
) -> Result<String, NodeError>
[src]

pub async fn get_raw_transaction<'_, '_>(
    &'_ self,
    tx_id: &'_ [u8]
) -> Result<Vec<u8>, NodeError>
[src]

Methods from Deref<Target = HttpClient<C>>

pub fn next_nonce(&self) -> usize[src]

pub async fn send(&'_ self, request: Request) -> Result<Response, Error<Error>>[src]

Trait Implementations

impl<C: Clone> Clone for BitcoinClient<C>[src]

impl<C: Debug> Debug for BitcoinClient<C>[src]

impl<C> Deref for BitcoinClient<C>[src]

type Target = HttpClient<C>

The resulting type after dereferencing.

Auto Trait Implementations

impl<C> !RefUnwindSafe for BitcoinClient<C>

impl<C> Send for BitcoinClient<C> where
    C: Send

impl<C> Sync for BitcoinClient<C> where
    C: Sync

impl<C> Unpin for BitcoinClient<C> where
    C: Unpin

impl<C> !UnwindSafe for BitcoinClient<C>

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.