pub struct Request<T: FromRequest> {
pub req: T,
pub header: PacketHeader,
}Expand description
Structure wrapping a from request type to include a packet header to allow the response type to be created
Fields§
§req: TThe decoded request type
header: PacketHeaderThe packet header from the request
Implementations§
Trait Implementations§
Source§impl<T: FromRequest> Deref for Request<T>
Deref implementation so that the request fields can be
directly accessed
impl<T: FromRequest> Deref for Request<T>
Deref implementation so that the request fields can be directly accessed
Source§impl<T: FromRequest> FromRequest for Request<T>
impl<T: FromRequest> FromRequest for Request<T>
Source§fn from_request(req: &Packet) -> DecodeResult<Self>
fn from_request(req: &Packet) -> DecodeResult<Self>
Takes the value from the request returning a decode result of
whether the value could be created Read more
Auto Trait Implementations§
impl<T> Freeze for Request<T>where
T: Freeze,
impl<T> RefUnwindSafe for Request<T>where
T: RefUnwindSafe,
impl<T> Send for Request<T>
impl<T> Sync for Request<T>where
T: Sync,
impl<T> Unpin for Request<T>where
T: Unpin,
impl<T> UnsafeUnpin for Request<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for Request<T>where
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more