[−]Enum pnet::packet::MutPacketData
Mutable packet data.
Variants
Owned mutable packet data.
Borrowed mutable packet data.
Implementations
impl<'p> MutPacketData<'p>
pub fn as_slice(&self) -> &[u8]
Get packet data as a slice.
pub fn as_mut_slice(&mut self) -> &mut [u8]
Get packet data as a mutable slice.
pub fn to_immutable(self) -> PacketData<'p>
Get an immutable version of packet data.
pub fn len(&self) -> usize
Get a length of data in the packet.
Trait Implementations
impl<'p> Index<Range<usize>> for MutPacketData<'p>
type Output = [u8]
The returned type after indexing.
pub fn index(&self, index: Range<usize>) -> &[u8]
impl<'p> Index<RangeFrom<usize>> for MutPacketData<'p>
type Output = [u8]
The returned type after indexing.
pub fn index(&self, index: RangeFrom<usize>) -> &[u8]
impl<'p> Index<RangeFull> for MutPacketData<'p>
impl<'p> Index<RangeTo<usize>> for MutPacketData<'p>
type Output = [u8]
The returned type after indexing.
pub fn index(&self, index: RangeTo<usize>) -> &[u8]
impl<'p> Index<usize> for MutPacketData<'p>
impl<'p> IndexMut<Range<usize>> for MutPacketData<'p>
impl<'p> IndexMut<RangeFrom<usize>> for MutPacketData<'p>
impl<'p> IndexMut<RangeFull> for MutPacketData<'p>
impl<'p> IndexMut<RangeTo<usize>> for MutPacketData<'p>
impl<'p> IndexMut<usize> for MutPacketData<'p>
impl<'p> PartialEq<MutPacketData<'p>> for MutPacketData<'p>
pub fn eq(&self, other: &MutPacketData<'p>) -> bool
pub fn ne(&self, other: &MutPacketData<'p>) -> bool
impl<'p> StructuralPartialEq for MutPacketData<'p>
Auto Trait Implementations
impl<'p> RefUnwindSafe for MutPacketData<'p>
impl<'p> Send for MutPacketData<'p>
impl<'p> Sync for MutPacketData<'p>
impl<'p> Unpin for MutPacketData<'p>
impl<'p> !UnwindSafe for MutPacketData<'p>
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,