[−][src]Struct easy_http_request::HttpRequest
The http request sender. See DefaultHttpRequest
or StaticHttpRequest
.
Fields
method: HttpRequestMethod
url: Url
query: Option<HashMap<QK, QV>>
body: Option<HttpRequestBody<BK, BV>>
headers: Option<HashMap<HK, HV>>
options: HttpRequestOptions
Methods
impl<QK: Eq + Hash + AsRef<str>, QV: AsRef<str>, BK: Eq + Hash + AsRef<str>, BV: AsRef<str>, HK: Eq + Hash + AsRef<str>, HV: AsRef<str>> HttpRequest<QK, QV, BK, BV, HK, HV>
[src]
pub fn new(
method: HttpRequestMethod,
url: Url
) -> HttpRequest<QK, QV, BK, BV, HK, HV>
[src]
method: HttpRequestMethod,
url: Url
) -> HttpRequest<QK, QV, BK, BV, HK, HV>
pub fn get(url: Url) -> HttpRequest<QK, QV, BK, BV, HK, HV>
[src]
pub fn get_from_url_str<S: AsRef<str>>(
url: S
) -> Result<HttpRequest<QK, QV, BK, BV, HK, HV>, HttpRequestError>
[src]
url: S
) -> Result<HttpRequest<QK, QV, BK, BV, HK, HV>, HttpRequestError>
pub fn post(url: Url) -> HttpRequest<QK, QV, BK, BV, HK, HV>
[src]
pub fn post_from_url_str<S: AsRef<str>>(
url: S
) -> Result<HttpRequest<QK, QV, BK, BV, HK, HV>, HttpRequestError>
[src]
url: S
) -> Result<HttpRequest<QK, QV, BK, BV, HK, HV>, HttpRequestError>
pub fn put(url: Url) -> HttpRequest<QK, QV, BK, BV, HK, HV>
[src]
pub fn put_from_url_str<S: AsRef<str>>(
url: S
) -> Result<HttpRequest<QK, QV, BK, BV, HK, HV>, HttpRequestError>
[src]
url: S
) -> Result<HttpRequest<QK, QV, BK, BV, HK, HV>, HttpRequestError>
pub fn delete(url: Url) -> HttpRequest<QK, QV, BK, BV, HK, HV>
[src]
pub fn delete_from_url_str<S: AsRef<str>>(
url: S
) -> Result<HttpRequest<QK, QV, BK, BV, HK, HV>, HttpRequestError>
[src]
url: S
) -> Result<HttpRequest<QK, QV, BK, BV, HK, HV>, HttpRequestError>
pub fn head(url: Url) -> HttpRequest<QK, QV, BK, BV, HK, HV>
[src]
pub fn head_from_url_str<S: AsRef<str>>(
url: S
) -> Result<HttpRequest<QK, QV, BK, BV, HK, HV>, HttpRequestError>
[src]
url: S
) -> Result<HttpRequest<QK, QV, BK, BV, HK, HV>, HttpRequestError>
pub fn send(self) -> Result<HttpResponse, HttpRequestError>
[src]
Send a request and drop this sender.
pub fn send_preserved(&self) -> Result<HttpResponse, HttpRequestError>
[src]
Send a request and preserve this sender so that it can be used again.
Trait Implementations
impl<QK, QV, BK, BV, HK, HV> Clone for HttpRequest<QK, QV, BK, BV, HK, HV> where
QK: Eq + Hash + AsRef<str>,
QV: AsRef<str>,
BK: Eq + Hash + AsRef<str>,
BV: AsRef<str>,
HK: Eq + Hash + AsRef<str>,
HV: AsRef<str>,
QK: Clone,
QV: Clone,
BK: Clone,
BV: Clone,
HK: Clone,
HV: Clone,
[src]
QK: Eq + Hash + AsRef<str>,
QV: AsRef<str>,
BK: Eq + Hash + AsRef<str>,
BV: AsRef<str>,
HK: Eq + Hash + AsRef<str>,
HV: AsRef<str>,
QK: Clone,
QV: Clone,
BK: Clone,
BV: Clone,
HK: Clone,
HV: Clone,
fn clone(&self) -> Self
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl<QK, QV, BK, BV, HK, HV> Debug for HttpRequest<QK, QV, BK, BV, HK, HV> where
QK: Eq + Hash + AsRef<str>,
QV: AsRef<str>,
BK: Eq + Hash + AsRef<str>,
BV: AsRef<str>,
HK: Eq + Hash + AsRef<str>,
HV: AsRef<str>,
QK: Debug,
QV: Debug,
BK: Debug,
BV: Debug,
HK: Debug,
HV: Debug,
[src]
QK: Eq + Hash + AsRef<str>,
QV: AsRef<str>,
BK: Eq + Hash + AsRef<str>,
BV: AsRef<str>,
HK: Eq + Hash + AsRef<str>,
HV: AsRef<str>,
QK: Debug,
QV: Debug,
BK: Debug,
BV: Debug,
HK: Debug,
HV: Debug,
Auto Trait Implementations
impl<QK, QV, BK, BV, HK, HV> Unpin for HttpRequest<QK, QV, BK, BV, HK, HV> where
BK: Unpin,
BV: Unpin,
HK: Unpin,
HV: Unpin,
QK: Unpin,
QV: Unpin,
BK: Unpin,
BV: Unpin,
HK: Unpin,
HV: Unpin,
QK: Unpin,
QV: Unpin,
impl<QK, QV, BK, BV, HK, HV> Sync for HttpRequest<QK, QV, BK, BV, HK, HV> where
BK: Sync,
BV: Sync,
HK: Sync,
HV: Sync,
QK: Sync,
QV: Sync,
BK: Sync,
BV: Sync,
HK: Sync,
HV: Sync,
QK: Sync,
QV: Sync,
impl<QK, QV, BK, BV, HK, HV> Send for HttpRequest<QK, QV, BK, BV, HK, HV> where
BK: Send,
BV: Send,
HK: Send,
HV: Send,
QK: Send,
QV: Send,
BK: Send,
BV: Send,
HK: Send,
HV: Send,
QK: Send,
QV: Send,
impl<QK, QV, BK, BV, HK, HV> RefUnwindSafe for HttpRequest<QK, QV, BK, BV, HK, HV> where
BK: RefUnwindSafe,
BV: RefUnwindSafe,
HK: RefUnwindSafe,
HV: RefUnwindSafe,
QK: RefUnwindSafe,
QV: RefUnwindSafe,
BK: RefUnwindSafe,
BV: RefUnwindSafe,
HK: RefUnwindSafe,
HV: RefUnwindSafe,
QK: RefUnwindSafe,
QV: RefUnwindSafe,
impl<QK, QV, BK, BV, HK, HV> UnwindSafe for HttpRequest<QK, QV, BK, BV, HK, HV> where
BK: UnwindSafe,
BV: UnwindSafe,
HK: UnwindSafe,
HV: UnwindSafe,
QK: UnwindSafe,
QV: UnwindSafe,
BK: UnwindSafe,
BV: UnwindSafe,
HK: UnwindSafe,
HV: UnwindSafe,
QK: UnwindSafe,
QV: UnwindSafe,
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Typeable for T where
T: Any,
T: Any,