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