[−][src]Struct twilight_http::request::Request
Fields
body: Option<Vec<u8>>
The body of the request, if any.
form: Option<Form>
The multipart form of the request, if any.
headers: Option<HeaderMap<HeaderValue>>
The headers to set in the request, if any.
method: Method
The method of the request.
path: Path
The ratelimiting bucket path.
path_str: Cow<'static, str>
The URI path to request.
Implementations
impl Request
[src]
pub fn new(
body: Option<Vec<u8>>,
headers: Option<HeaderMap<HeaderValue>>,
route: Route
) -> Self
[src]
body: Option<Vec<u8>>,
headers: Option<HeaderMap<HeaderValue>>,
route: Route
) -> Self
Create a simple Request
with basic information.
Use the various From
implementations for different combinations of
configurations.
Trait Implementations
impl Debug for Request
[src]
impl From<(Form, Route)> for Request
[src]
impl From<(HeaderMap<HeaderValue>, Route)> for Request
[src]
impl From<(Vec<u8, Global>, Form, Route)> for Request
[src]
impl From<(Vec<u8, Global>, HeaderMap<HeaderValue>, Route)> for Request
[src]
impl From<(Vec<u8, Global>, Route)> for Request
[src]
impl From<Route> for Request
[src]
Auto Trait Implementations
impl RefUnwindSafe for Request
[src]
impl Send for Request
[src]
impl Sync for Request
[src]
impl Unpin for Request
[src]
impl UnwindSafe for Request
[src]
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T> Instrument for T
[src]
pub fn instrument(self, span: Span) -> Instrumented<Self>
[src]
pub fn in_current_span(self) -> Instrumented<Self>
[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.
pub 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.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,