Struct web3::api::Web3[][src]

pub struct Web3<T: Transport> { /* fields omitted */ }
Expand description

Web3 wrapper for all namespaces

Implementations

impl<T: Transport> Web3<T>[src]

pub fn new(transport: T) -> Self[src]

Create new Web3 with given transport

pub fn transport(&self) -> &T[src]

Borrows a transport.

pub fn api<A: Namespace<T>>(&self) -> A[src]

Access methods from custom namespace

pub fn accounts(&self) -> Accounts<T>[src]

Access methods from accounts namespace

pub fn eth(&self) -> Eth<T>[src]

Access methods from eth namespace

pub fn net(&self) -> Net<T>[src]

Access methods from net namespace

pub fn web3(&self) -> Web3<T>[src]

Access methods from web3 namespace

pub fn eth_filter(&self) -> EthFilter<T>[src]

Access filter methods from eth namespace

pub fn parity(&self) -> Parity<T>[src]

Access methods from parity namespace

pub fn parity_accounts(&self) -> ParityAccounts<T>[src]

Access methods from parity_accounts namespace

pub fn parity_set(&self) -> ParitySet<T>[src]

Access methods from parity_set namespace

pub fn personal(&self) -> Personal<T>[src]

Access methods from personal namespace

pub fn trace(&self) -> Traces<T>[src]

Access methods from trace namespace

pub fn txpool(&self) -> Txpool<T>[src]

Access methods from txpool namespace

pub async fn wait_for_confirmations<F, V>(
    &self,
    poll_interval: Duration,
    confirmations: usize,
    check: V
) -> Result<()> where
    F: Future<Output = Result<Option<U64>>>,
    V: ConfirmationCheck<Check = F>, 
[src]

Should be used to wait for confirmations

pub async fn send_transaction_with_confirmation(
    &self,
    tx: TransactionRequest,
    poll_interval: Duration,
    confirmations: usize
) -> Result<TransactionReceipt>
[src]

Sends transaction and returns future resolved after transaction is confirmed

pub async fn send_raw_transaction_with_confirmation(
    &self,
    tx: Bytes,
    poll_interval: Duration,
    confirmations: usize
) -> Result<TransactionReceipt>
[src]

Sends raw transaction and returns future resolved after transaction is confirmed

impl<T: DuplexTransport> Web3<T>[src]

pub fn eth_subscribe(&self) -> EthSubscribe<T>[src]

Access subscribe methods from eth namespace

Trait Implementations

impl<T: Clone + Transport> Clone for Web3<T>[src]

fn clone(&self) -> Web3<T>[src]

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl<T: Debug + Transport> Debug for Web3<T>[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl<T> RefUnwindSafe for Web3<T> where
    T: RefUnwindSafe

impl<T> Send for Web3<T> where
    T: Send

impl<T> Sync for Web3<T> where
    T: Sync

impl<T> Unpin for Web3<T> where
    T: Unpin

impl<T> UnwindSafe for Web3<T> where
    T: UnwindSafe

Blanket Implementations

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

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

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

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

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

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

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

pub fn from(t: T) -> T[src]

Performs the conversion.

impl<T> Instrument for T[src]

fn instrument(self, span: Span) -> Instrumented<Self>[src]

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

fn in_current_span(self) -> Instrumented<Self>[src]

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

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

pub fn into(self) -> U[src]

Performs the conversion.

impl<T> Same<T> for T

type Output = T

Should always be Self

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

type Owned = T

The resulting type after obtaining ownership.

pub fn to_owned(&self) -> T[src]

Creates owned data from borrowed data, usually by cloning. Read more

pub fn clone_into(&self, target: &mut T)[src]

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

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.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

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.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 

pub fn vzip(self) -> V