[][src]Trait jsonrpc::client::Transport

pub trait Transport: Send + Sync + 'static {
    pub fn send_request(&self, _: Request<'_>) -> Result<Response, Error>;
pub fn send_batch(&self, _: &[Request<'_>]) -> Result<Vec<Response>, Error>;
pub fn fmt_target(&self, f: &mut Formatter<'_>) -> Result; }

An interface for a transport over which to use the JSONRPC protocol.

Required methods

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

Send an RPC request over the transport.

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

Send a batch of RPC requests over the transport.

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

Format the target of this transport. I.e. the URL/socket/...

Loading content...

Implementors

impl Transport for SimpleHttpTransport[src]

Loading content...