ClientixRequestBuilder

Trait ClientixRequestBuilder 

Source
pub trait ClientixRequestBuilder {
    // Required methods
    fn config(&mut self) -> &mut RequestConfig;
    fn result(&mut self) -> &mut ClientixResult<()>;

    // Provided methods
    fn path(self, path: &str) -> Self
       where Self: Sized { ... }
    fn query(self, key: &str, value: &str) -> Self
       where Self: Sized { ... }
    fn queries(self, queries: HashMap<String, String>) -> Self
       where Self: Sized { ... }
    fn header(self, key: &str, value: &str) -> Self
       where Self: Sized { ... }
    fn headers(self, headers: HashMap<String, String>) -> Self
       where Self: Sized { ... }
    fn basic_auth(self, username: &str, password: &str) -> Self
       where Self: Sized { ... }
    fn bearer_auth(self, token: &str) -> Self
       where Self: Sized { ... }
    fn body<T: Serialize>(self, body: T, content_type: ContentType) -> Self
       where Self: Sized { ... }
}

Required Methods§

Source

fn config(&mut self) -> &mut RequestConfig

Source

fn result(&mut self) -> &mut ClientixResult<()>

Provided Methods§

Source

fn path(self, path: &str) -> Self
where Self: Sized,

Source

fn query(self, key: &str, value: &str) -> Self
where Self: Sized,

Source

fn queries(self, queries: HashMap<String, String>) -> Self
where Self: Sized,

Source

fn header(self, key: &str, value: &str) -> Self
where Self: Sized,

Source

fn headers(self, headers: HashMap<String, String>) -> Self
where Self: Sized,

Source

fn basic_auth(self, username: &str, password: &str) -> Self
where Self: Sized,

Source

fn bearer_auth(self, token: &str) -> Self
where Self: Sized,

Source

fn body<T: Serialize>(self, body: T, content_type: ContentType) -> Self
where Self: Sized,

Implementors§