pub struct AsyncResponseHandler { /* private fields */ }
Implementations§
Source§impl AsyncResponseHandler
impl AsyncResponseHandler
pub fn new(result: ClientixResult<Response>) -> AsyncResponseHandler
pub async fn bytes(self) -> ClientixResult<ClientixResponse<Bytes>>
pub fn bytes_stream(self) -> ClientixResult<ClientixStream>
pub async fn text(self) -> ClientixResult<ClientixResponse<String>>
pub async fn text_with_encoding( self, encoding: &str, ) -> ClientixResult<ClientixResponse<String>>
pub fn text_stream(self) -> ClientixResult<ClientixSSEStream<String>>
pub async fn json<T>(self) -> ClientixResult<ClientixResponse<T>>where
T: DeserializeOwned + Clone,
pub fn json_stream<T>(self) -> ClientixResult<ClientixSSEStream<T>>where
T: DeserializeOwned + Clone,
pub async fn xml<T>(self) -> ClientixResult<ClientixResponse<T>>where
T: DeserializeOwned + Clone,
pub async fn xml_stream<T>(self) -> ClientixResult<ClientixSSEStream<T>>where
T: DeserializeOwned + Clone,
pub async fn urlencoded<T>(self) -> ClientixResult<ClientixResponse<T>>where
T: DeserializeOwned + Clone,
Auto Trait Implementations§
impl Freeze for AsyncResponseHandler
impl !RefUnwindSafe for AsyncResponseHandler
impl Send for AsyncResponseHandler
impl Sync for AsyncResponseHandler
impl Unpin for AsyncResponseHandler
impl !UnwindSafe for AsyncResponseHandler
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