pub struct MessageMeta(pub Bytes);
Expand description
Extract the raw metadata of a message from a frame. This gives you the
unprocessed metadata of the message in Bytes
form. Other parts of
the system presume JSON encoding and things like that, but this
will let you determine what format you like.
Tuple Fields§
§0: Bytes
Trait Implementations§
Source§impl Clone for MessageMeta
impl Clone for MessageMeta
Source§fn clone(&self) -> MessageMeta
fn clone(&self) -> MessageMeta
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for MessageMeta
impl Debug for MessageMeta
Source§impl<State> Extractor<State> for MessageMeta
impl<State> Extractor<State> for MessageMeta
Source§type Error = MessageFrameError
type Error = MessageFrameError
The error type for this extractor. Anything that can be converted into an extractor error
can be used as an error type. Read more
Source§fn extract(frame: Frame, context: &Context<State>) -> Result<Self, Self::Error>where
Self: Sized,
fn extract(frame: Frame, context: &Context<State>) -> Result<Self, Self::Error>where
Self: Sized,
Take an frame and a state and return a result containing the extracted value or the frame.
Source§impl PartialEq for MessageMeta
impl PartialEq for MessageMeta
impl Eq for MessageMeta
impl StructuralPartialEq for MessageMeta
Auto Trait Implementations§
impl !Freeze for MessageMeta
impl RefUnwindSafe for MessageMeta
impl Send for MessageMeta
impl Sync for MessageMeta
impl Unpin for MessageMeta
impl UnwindSafe for MessageMeta
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