pub struct ARPSliceBuilder<'a> { /* private fields */ }
Expand description
ARP builder
Implementations§
Source§impl<'a> ARPSliceBuilder<'a>
impl<'a> ARPSliceBuilder<'a>
Sourcepub fn new(buf: &'a mut [u8]) -> Result<Self, Error>
pub fn new(buf: &'a mut [u8]) -> Result<Self, Error>
Create a new builder with a mutable buffer, initialize it with proper values
Sourcepub fn sender_hardware_addr(self, ether_addr: &[u8]) -> Result<Self, Error>
pub fn sender_hardware_addr(self, ether_addr: &[u8]) -> Result<Self, Error>
Update the sender hardware address
Sourcepub fn sender_protocol_addr(self, ipv4_addr: &[u8]) -> Result<Self, Error>
pub fn sender_protocol_addr(self, ipv4_addr: &[u8]) -> Result<Self, Error>
Update the sender protocol address
Sourcepub fn target_hardware_addr(self, ether_addr: &[u8]) -> Result<Self, Error>
pub fn target_hardware_addr(self, ether_addr: &[u8]) -> Result<Self, Error>
Update the target ethernet address
Sourcepub fn target_protocol_addr(self, ipv4_addr: &[u8]) -> Result<Self, Error>
pub fn target_protocol_addr(self, ipv4_addr: &[u8]) -> Result<Self, Error>
Update the target protocol address
Auto Trait Implementations§
impl<'a> Freeze for ARPSliceBuilder<'a>
impl<'a> RefUnwindSafe for ARPSliceBuilder<'a>
impl<'a> Send for ARPSliceBuilder<'a>
impl<'a> Sync for ARPSliceBuilder<'a>
impl<'a> Unpin for ARPSliceBuilder<'a>
impl<'a> !UnwindSafe for ARPSliceBuilder<'a>
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