[−][src]Struct packet_crafter::headers::ArpHeader
Methods
impl ArpHeader
[src]
pub fn get_opcode(&self) -> &u16
[src]
pub fn get_sender_mac(&self) -> &[u8; 6]
[src]
pub fn get_sender_ip(&self) -> &[u8; 4]
[src]
pub fn get_destination_mac(&self) -> &[u8; 6]
[src]
pub fn get_destination_ip(&self) -> &[u8; 4]
[src]
impl ArpHeader
[src]
pub fn set_opcode(&mut self, v: u16)
[src]
pub fn set_sender_mac(&mut self, v: [u8; 6])
[src]
pub fn set_sender_ip(&mut self, v: [u8; 4])
[src]
pub fn set_destination_mac(&mut self, v: [u8; 6])
[src]
pub fn set_destination_ip(&mut self, v: [u8; 4])
[src]
impl ArpHeader
[src]
pub fn new<T: Into<[u8; 4]>>(
sender_mac: [u8; 6],
sender_ip: T,
destination_mac: [u8; 6],
destination_ip: T
) -> Self
[src]
sender_mac: [u8; 6],
sender_ip: T,
destination_mac: [u8; 6],
destination_ip: T
) -> Self
Trait Implementations
impl Header for ArpHeader
[src]
fn make(self) -> PacketData
[src]
fn parse(raw_data: &[u8]) -> Result<Box<Self>, ParseError>
[src]
fn get_proto(&self) -> Protocol
[src]
fn get_length(&self) -> u8
[src]
fn get_min_length() -> u8
[src]
Auto Trait Implementations
impl RefUnwindSafe for ArpHeader
impl Send for ArpHeader
impl Sync for ArpHeader
impl Unpin for ArpHeader
impl UnwindSafe for ArpHeader
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,
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.
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>,