Struct conjure_runtime::Client
source · pub struct Client<T = DefaultRawClient> { /* private fields */ }
Expand description
An asynchronous HTTP client to a remote service.
It implements the Conjure AsyncClient
trait, but also offers a “raw” request interface for use with services that
don’t provide Conjure service definitions.
Implementations§
Trait Implementations§
source§impl<T, B> AsyncClient for Client<T>
impl<T, B> AsyncClient for Client<T>
§type BodyWriter = BodyWriter
type BodyWriter = BodyWriter
The client’s binary request body write type.
§type ResponseBody = ResponseBody<B>
type ResponseBody = ResponseBody<B>
The client’s binary response body type.
source§fn send<'life0, 'life1, 'async_trait>(
&'life0 self,
request: Request<AsyncRequestBody<'life1, Self::BodyWriter>>
) -> Pin<Box<dyn Future<Output = Result<Response<Self::ResponseBody>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn send<'life0, 'life1, 'async_trait>(
&'life0 self,
request: Request<AsyncRequestBody<'life1, Self::BodyWriter>>
) -> Pin<Box<dyn Future<Output = Result<Response<Self::ResponseBody>, Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Makes an HTTP request. Read more
source§impl<T> AsyncService<Client<T>> for Client<T>
impl<T> AsyncService<Client<T>> for Client<T>
Auto Trait Implementations§
impl<T> Freeze for Client<T>
impl<T = DefaultRawClient> !RefUnwindSafe for Client<T>
impl<T> Send for Client<T>
impl<T> Sync for Client<T>
impl<T> Unpin for Client<T>
impl<T = DefaultRawClient> !UnwindSafe for Client<T>
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