pub struct Request<T> { /* private fields */ }Expand description
An outbound or decoded request with application metadata.
Implementations§
Source§impl<T> Request<T>
impl<T> Request<T>
Sourcepub const fn from_parts(metadata: Metadata, message: T) -> Request<T>
pub const fn from_parts(metadata: Metadata, message: T) -> Request<T>
Combines application metadata and a message.
Sourcepub const fn metadata_mut(&mut self) -> &mut Metadata
pub const fn metadata_mut(&mut self) -> &mut Metadata
Mutably borrows the application metadata.
Sourcepub fn into_parts(self) -> (Metadata, T)
pub fn into_parts(self) -> (Metadata, T)
Consumes the envelope, returning application metadata and the message.
Trait Implementations§
impl<T> Eq for Request<T>where
T: Eq,
impl<T> StructuralPartialEq for Request<T>where
T: PartialEq,
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>where
T: Send,
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