pub enum PacketData<'p> {
Owned(Vec<u8>),
Borrowed(&'p [u8]),
}
Expand description
Packet data.
Variants§
Implementations§
Source§impl<'p> PacketData<'p>
impl<'p> PacketData<'p>
Sourcepub fn to_immutable(self) -> PacketData<'p>
pub fn to_immutable(self) -> PacketData<'p>
No-op - returns self
.
Trait Implementations§
Source§impl<'p> Index<RangeFull> for PacketData<'p>
impl<'p> Index<RangeFull> for PacketData<'p>
Source§impl<'p> Index<usize> for PacketData<'p>
impl<'p> Index<usize> for PacketData<'p>
Source§impl<'p> PartialEq for PacketData<'p>
impl<'p> PartialEq for PacketData<'p>
impl<'p> StructuralPartialEq for PacketData<'p>
Auto Trait Implementations§
impl<'p> Freeze for PacketData<'p>
impl<'p> RefUnwindSafe for PacketData<'p>
impl<'p> Send for PacketData<'p>
impl<'p> Sync for PacketData<'p>
impl<'p> Unpin for PacketData<'p>
impl<'p> UnwindSafe for PacketData<'p>
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