Struct ntex::http::client::FrozenClientRequest [−][src]
pub struct FrozenClientRequest { /* fields omitted */ }
Expand description
FrozenClientRequest
struct represents clonable client request.
It could be used to send same request multiple times.
Implementations
impl FrozenClientRequest
[src]
impl FrozenClientRequest
[src]pub fn get_method(&self) -> &Method
[src]
pub fn get_method(&self) -> &Method
[src]Get HTTP method of this request
pub fn send_body<B>(&self, body: B) -> SendClientRequestⓘNotable traits for SendClientRequest
impl Future for SendClientRequest type Output = Result<ClientResponse, SendRequestError>;
where
B: Into<Body>,
[src]
pub fn send_body<B>(&self, body: B) -> SendClientRequestⓘNotable traits for SendClientRequest
impl Future for SendClientRequest type Output = Result<ClientResponse, SendRequestError>;
where
B: Into<Body>,
[src]Send a body.
pub fn send_json<T: Serialize>(&self, value: &T) -> SendClientRequestⓘNotable traits for SendClientRequest
impl Future for SendClientRequest type Output = Result<ClientResponse, SendRequestError>;
[src]
pub fn send_json<T: Serialize>(&self, value: &T) -> SendClientRequestⓘNotable traits for SendClientRequest
impl Future for SendClientRequest type Output = Result<ClientResponse, SendRequestError>;
[src]Send a json body.
pub fn send_form<T: Serialize>(&self, value: &T) -> SendClientRequestⓘNotable traits for SendClientRequest
impl Future for SendClientRequest type Output = Result<ClientResponse, SendRequestError>;
[src]
pub fn send_form<T: Serialize>(&self, value: &T) -> SendClientRequestⓘNotable traits for SendClientRequest
impl Future for SendClientRequest type Output = Result<ClientResponse, SendRequestError>;
[src]Send an urlencoded body.
pub fn send_stream<S, E>(&self, stream: S) -> SendClientRequestⓘNotable traits for SendClientRequest
impl Future for SendClientRequest type Output = Result<ClientResponse, SendRequestError>;
where
S: Stream<Item = Result<Bytes, E>> + Unpin + 'static,
E: Error + 'static,
[src]
pub fn send_stream<S, E>(&self, stream: S) -> SendClientRequestⓘNotable traits for SendClientRequest
impl Future for SendClientRequest type Output = Result<ClientResponse, SendRequestError>;
where
S: Stream<Item = Result<Bytes, E>> + Unpin + 'static,
E: Error + 'static,
[src]Send a streaming body.
pub fn send(&self) -> SendClientRequestⓘNotable traits for SendClientRequest
impl Future for SendClientRequest type Output = Result<ClientResponse, SendRequestError>;
[src]
pub fn send(&self) -> SendClientRequestⓘNotable traits for SendClientRequest
impl Future for SendClientRequest type Output = Result<ClientResponse, SendRequestError>;
[src]Send an empty body.
pub fn extra_headers(&self, extra_headers: HeaderMap) -> FrozenSendBuilder
[src]
pub fn extra_headers(&self, extra_headers: HeaderMap) -> FrozenSendBuilder
[src]Create a FrozenSendBuilder
with extra headers
pub fn extra_header<K, V>(&self, key: K, value: V) -> FrozenSendBuilder where
HeaderName: TryFrom<K>,
HeaderValue: TryFrom<V>,
<HeaderName as TryFrom<K>>::Error: Into<HttpError>,
<HeaderValue as TryFrom<V>>::Error: Into<HttpError>,
[src]
pub fn extra_header<K, V>(&self, key: K, value: V) -> FrozenSendBuilder where
HeaderName: TryFrom<K>,
HeaderValue: TryFrom<V>,
<HeaderName as TryFrom<K>>::Error: Into<HttpError>,
<HeaderValue as TryFrom<V>>::Error: Into<HttpError>,
[src]Create a FrozenSendBuilder
with an extra header
Trait Implementations
impl Clone for FrozenClientRequest
[src]
impl Clone for FrozenClientRequest
[src]fn clone(&self) -> FrozenClientRequest
[src]
fn clone(&self) -> FrozenClientRequest
[src]Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl !RefUnwindSafe for FrozenClientRequest
impl !Send for FrozenClientRequest
impl !Sync for FrozenClientRequest
impl Unpin for FrozenClientRequest
impl !UnwindSafe for FrozenClientRequest
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> Instrument for T
[src]
impl<T> Instrument for T
[src]fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
fn in_current_span(self) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]impl<T> Same<T> for T
impl<T> Same<T> for T
type Output = T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more