pub struct Client { /* private fields */ }Implementations§
source§impl Client
impl Client
pub fn build() -> Self
pub fn header(self, key: &str, value: &str) -> Self
pub fn body<T>(self, t: &T) -> Selfwhere T: ?Sized + Serialize,
pub async fn get_string(&self) -> String
pub async fn get_as<T>(&self) -> Result<T, Status>where T: DeserializeOwned,
pub async fn get(&mut self, url: &str)
pub async fn post(&mut self, url: &str)
pub fn do_request(&self) -> ResultApiFuture<HttpResponse> ⓘ
pub fn get_body(&self) -> BytesApiFuture ⓘ
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for Client
impl Send for Client
impl Sync for Client
impl Unpin for Client
impl UnwindSafe for Client
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