pub struct ArpPacketBuilder { /* private fields */ }Expand description
Builder for ARP packets (Ethernet/IPv4).
Implementations§
Source§impl ArpPacketBuilder
impl ArpPacketBuilder
pub fn hardware_type(self, ht: ArpHardwareType) -> Self
pub fn protocol_type(self, pt: EtherType) -> Self
pub fn operation(self, op: ArpOperation) -> Self
pub fn sender_hw_addr(self, addr: &[u8]) -> Result<Self, BuildError>
pub fn sender_proto_addr(self, addr: &[u8]) -> Result<Self, BuildError>
pub fn target_hw_addr(self, addr: &[u8]) -> Result<Self, BuildError>
pub fn target_proto_addr(self, addr: &[u8]) -> Result<Self, BuildError>
pub fn build(self) -> Vec<u8>
Trait Implementations§
Source§impl Clone for ArpPacketBuilder
impl Clone for ArpPacketBuilder
Source§fn clone(&self) -> ArpPacketBuilder
fn clone(&self) -> ArpPacketBuilder
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ArpPacketBuilder
impl Debug for ArpPacketBuilder
Auto Trait Implementations§
impl Freeze for ArpPacketBuilder
impl RefUnwindSafe for ArpPacketBuilder
impl Send for ArpPacketBuilder
impl Sync for ArpPacketBuilder
impl Unpin for ArpPacketBuilder
impl UnsafeUnpin for ArpPacketBuilder
impl UnwindSafe for ArpPacketBuilder
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