pub enum EncodedPayload<'a> {
Borrowed(&'a [u8]),
Owned(Vec<u8>),
}Expand description
Represents an encoded payload body, either borrowed from the original value or materialized into an owned buffer.
Variants§
Borrowed(&'a [u8])
Bytes borrowed from an existing encoded representation.
Owned(Vec<u8>)
Bytes materialized into an owned buffer.
Implementations§
Auto Trait Implementations§
impl<'a> Freeze for EncodedPayload<'a>
impl<'a> RefUnwindSafe for EncodedPayload<'a>
impl<'a> Send for EncodedPayload<'a>
impl<'a> Sync for EncodedPayload<'a>
impl<'a> Unpin for EncodedPayload<'a>
impl<'a> UnsafeUnpin for EncodedPayload<'a>
impl<'a> UnwindSafe for EncodedPayload<'a>
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