Trait Target

Source
pub trait Target {
    // Required methods
    fn base_url(&self) -> &'static str;
    fn method(&self) -> HTTPMethod;
    fn path(&self) -> String;
    fn query(&self) -> HashMap<&'static str, &'static str>;
    fn headers(&self) -> HashMap<&'static str, &'static str>;
    fn authentication(&self) -> Option<AuthMethod>;
    fn body(&self) -> HTTPBody;
    fn timeout(&self) -> Option<Duration>;

    // Provided methods
    fn query_string(&self) -> String { ... }
    fn absolute_url(&self) -> String { ... }
}

Required Methods§

Source

fn base_url(&self) -> &'static str

Source

fn method(&self) -> HTTPMethod

Source

fn path(&self) -> String

Source

fn query(&self) -> HashMap<&'static str, &'static str>

Source

fn headers(&self) -> HashMap<&'static str, &'static str>

Source

fn authentication(&self) -> Option<AuthMethod>

Source

fn body(&self) -> HTTPBody

Source

fn timeout(&self) -> Option<Duration>

Provided Methods§

Implementors§