Enum fire_http::request::RequestBuilder
source · [−]pub enum RequestBuilder<'a> {
Hyper {
hyper_req: HyperRequest,
address: SocketAddr,
configs: &'a RequestConfigs,
},
Fire(Request),
ConvertError(HeaderError),
}Expand description
a container that contains a HyperRequest or a Fire Request if you receive this in a RawRoute you always receiver a hyper request
Variants
Hyper
Fire(Request)
ConvertError(HeaderError)
Implementations
sourceimpl<'a> RequestBuilder<'a>
impl<'a> RequestBuilder<'a>
sourcepub fn hyper_mut(&mut self) -> Option<&mut HyperRequest>
pub fn hyper_mut(&mut self) -> Option<&mut HyperRequest>
if you receive this in a raw request you can unwrap
sourcepub fn hyper_ref(&self) -> Option<&HyperRequest>
pub fn hyper_ref(&self) -> Option<&HyperRequest>
if you receive this in a raw request you can unwrap
sourcepub fn fire_mut(&mut self) -> Result<&mut Request, HeaderError>
pub fn fire_mut(&mut self) -> Result<&mut Request, HeaderError>
if this is called once the hyper request is gone if this returns Error You are not allowed to call it again it will panic
pub fn into_fire(self) -> Result<Request, HeaderError>
Trait Implementations
Auto Trait Implementations
impl<'a> !RefUnwindSafe for RequestBuilder<'a>
impl<'a> Send for RequestBuilder<'a>
impl<'a> Sync for RequestBuilder<'a>
impl<'a> Unpin for RequestBuilder<'a>
impl<'a> !UnwindSafe for RequestBuilder<'a>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
fn vzip(self) -> V
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
Attaches the provided Subscriber to this type, returning a
WithDispatch wrapper. Read more
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber to this type, returning a
WithDispatch wrapper. Read more