Struct witty_jsonrpc::transports::http::HttpTransport
source · pub struct HttpTransport<H>where
H: Handler,{ /* private fields */ }Expand description
A JSON-RPC over HTTP transport built around the jsonrpc_http_server library.
Implementations§
source§impl<H> HttpTransport<H>where
H: Handler,
impl<H> HttpTransport<H>where H: Handler,
sourcepub fn new(settings: HttpTransportSettings) -> Self
pub fn new(settings: HttpTransportSettings) -> Self
Create a new instance of this transport.
Trait Implementations§
source§impl<H> Transport<H> for HttpTransport<H>where
H: Handler,
H::Metadata: Default,
impl<H> Transport<H> for HttpTransport<H>where H: Handler, H::Metadata: Default,
source§fn requires_reset(&self) -> bool
fn requires_reset(&self) -> bool
Tell whether this transport requires reconfiguration if the IO handler of the server is
changed. Read more
source§fn set_handler(&mut self, handler: Arc<Mutex<H>>) -> Result<(), TransportError>
fn set_handler(&mut self, handler: Arc<Mutex<H>>) -> Result<(), TransportError>
Set the IO handler that the transport will use to process the JSON-RPC messages it receives..
Auto Trait Implementations§
impl<H> !RefUnwindSafe for HttpTransport<H>
impl<H> Send for HttpTransport<H>
impl<H> Sync for HttpTransport<H>
impl<H> Unpin for HttpTransport<H>
impl<H> !UnwindSafe for HttpTransport<H>
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