pub struct Client { /* private fields */ }
Implementations§
Source§impl Client
impl Client
pub fn new(consumer_key: &str, consumer_secret: &str) -> Option<Self>
pub fn new_by_env() -> Result<Option<Self>, VarError>
pub fn get( &self, url: &str, query_options: &Vec<(&str, &str)>, ) -> Result<Response, Error>
pub fn post( &self, url: &str, query_options: &Vec<(&str, &str)>, form_options: &Vec<(&str, &str)>, ) -> Result<Response, Error>
pub fn json( &self, url: &str, query_options: &Vec<(&str, &str)>, data: Value, ) -> Result<Response, Error>
pub fn put( &self, url: &str, query_options: &Vec<(&str, &str)>, ) -> Result<Response, Error>
pub fn delete( &self, url: &str, query_options: &Vec<(&str, &str)>, ) -> Result<Response, Error>
pub fn multipart( &self, url: &str, query_options: &Vec<(&str, &str)>, data: MultiPart, ) -> Result<Response, Error>
Auto Trait Implementations§
impl Freeze for Client
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