[][src]Trait web3_etz::Transport

pub trait Transport: Debug + Clone {
    type Out: Future<Item = Value, Error = Error>;
    fn prepare(&self, method: &str, params: Vec<Value>) -> (RequestId, Call);
fn send(&self, id: RequestId, request: Call) -> Self::Out; fn execute(&self, method: &str, params: Vec<Value>) -> Self::Out { ... } }

Transport implementation

Associated Types

type Out: Future<Item = Value, Error = Error>

The type of future this transport returns when a call is made.

Loading content...

Required methods

fn prepare(&self, method: &str, params: Vec<Value>) -> (RequestId, Call)

Prepare serializable RPC call for given method with parameters.

fn send(&self, id: RequestId, request: Call) -> Self::Out

Execute prepared RPC call.

Loading content...

Provided methods

fn execute(&self, method: &str, params: Vec<Value>) -> Self::Out

Execute remote method with given parameters.

Loading content...

Implementors

impl Transport for Http[src]

type Out = FetchTask<fn(_: Chunk) -> Result<Value>>

impl Transport for Ipc[src]

type Out = IpcTask<fn(_: Vec<Result<Value>>) -> Result<Value>>

impl Transport for WebSocket[src]

type Out = WsTask<fn(_: Vec<Result<Value>>) -> Result<Value>>

impl<T> Transport for Batch<T> where
    T: BatchTransport
[src]

type Out = SingleResult

impl<X, T: ?Sized> Transport for X where
    T: Transport,
    X: Deref<Target = T>,
    X: Debug,
    X: Clone
[src]

type Out = T::Out

Loading content...