pub struct RequestConfig { /* private fields */ }
Implementations§
Source§impl RequestConfig
impl RequestConfig
pub fn new() -> Self
pub fn get_path(&self) -> &String
pub fn set_path(&mut self, path: &str)
pub fn get_queries(&self) -> &Vec<(String, String)>
pub fn add_query(&mut self, key: &str, value: &str)
pub fn add_queries(&mut self, queries: HashMap<String, String>)
pub fn set_queries(&mut self, queries: HashMap<String, String>)
pub fn get_headers(&self) -> &HeaderMap
pub fn set_header(&mut self, key: &str, value: &str, sensitive: bool)
pub fn set_headers(&mut self, headers: HashMap<String, String>)
pub fn basic_auth(&mut self, username: &str, password: &str)
pub fn bearer_auth(&mut self, token: &str)
pub fn get_body(&self) -> &Option<String>
pub fn set_body<T: Serialize>( &mut self, body: T, content_type: ContentType, ) -> ClientixResult<()>
pub fn get_timeout(&self) -> Option<Duration>
pub fn set_timeout(&mut self, timeout: Duration)
Trait Implementations§
Source§impl Clone for RequestConfig
impl Clone for RequestConfig
Source§fn clone(&self) -> RequestConfig
fn clone(&self) -> RequestConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for RequestConfig
impl Debug for RequestConfig
Source§impl Default for RequestConfig
impl Default for RequestConfig
Source§fn default() -> RequestConfig
fn default() -> RequestConfig
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for RequestConfig
impl RefUnwindSafe for RequestConfig
impl Send for RequestConfig
impl Sync for RequestConfig
impl Unpin for RequestConfig
impl UnwindSafe for RequestConfig
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