pub struct Client<C>(/* private fields */);Implementations§
Source§impl<C> Client<C>where
C: Connection,
impl<C> Client<C>where
C: Connection,
pub fn wrap(connection: C) -> Self
pub fn connection(&mut self) -> &mut C
pub fn release(self) -> C
pub fn get<'a>( &'a mut self, uri: &'a str, ) -> Result<Request<&'a mut C>, C::Error>
pub fn post<'a>( &'a mut self, uri: &'a str, headers: &'a [(&'a str, &'a str)], ) -> Result<Request<&'a mut C>, C::Error>
pub fn put<'a>( &'a mut self, uri: &'a str, headers: &'a [(&'a str, &'a str)], ) -> Result<Request<&'a mut C>, C::Error>
pub fn delete<'a>( &'a mut self, uri: &'a str, ) -> Result<Request<&'a mut C>, C::Error>
pub fn request<'a>( &'a mut self, method: Method, uri: &'a str, headers: &'a [(&'a str, &'a str)], ) -> Result<Request<&'a mut C>, C::Error>
pub fn raw_connection(&mut self) -> Result<&mut C::RawConnection, C::Error>
Trait Implementations§
Auto Trait Implementations§
impl<C> Freeze for Client<C>where
C: Freeze,
impl<C> RefUnwindSafe for Client<C>where
C: RefUnwindSafe,
impl<C> Send for Client<C>where
C: Send,
impl<C> Sync for Client<C>where
C: Sync,
impl<C> Unpin for Client<C>where
C: Unpin,
impl<C> UnsafeUnpin for Client<C>where
C: UnsafeUnpin,
impl<C> UnwindSafe for Client<C>where
C: UnwindSafe,
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