pub struct EthernetBuilder { /* private fields */ }Implementations§
Source§impl EthernetBuilder
impl EthernetBuilder
pub fn new() -> Self
pub fn dst(self, mac: MacAddress) -> Self
pub fn src(self, mac: MacAddress) -> Self
pub fn ethertype(self, etype: u16) -> Self
pub fn build(&self) -> Vec<u8> ⓘ
pub fn build_into(&self, buf: &mut [u8]) -> Result<(), FieldError>
pub fn build_with_payload(&self, payload_kind: LayerKind) -> Vec<u8> ⓘ
Trait Implementations§
Source§impl Clone for EthernetBuilder
impl Clone for EthernetBuilder
Source§fn clone(&self) -> EthernetBuilder
fn clone(&self) -> EthernetBuilder
Returns a duplicate of the value. Read more
1.0.0 · 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 EthernetBuilder
impl Debug for EthernetBuilder
Source§impl Default for EthernetBuilder
impl Default for EthernetBuilder
Source§impl From<EthernetBuilder> for LayerStack
impl From<EthernetBuilder> for LayerStack
Source§fn from(builder: EthernetBuilder) -> Self
fn from(builder: EthernetBuilder) -> Self
Converts to this type from the input type.
Source§impl IntoLayerStackEntry for EthernetBuilder
impl IntoLayerStackEntry for EthernetBuilder
fn into_layer_stack_entry(self) -> LayerStackEntry
Auto Trait Implementations§
impl Freeze for EthernetBuilder
impl RefUnwindSafe for EthernetBuilder
impl Send for EthernetBuilder
impl Sync for EthernetBuilder
impl Unpin for EthernetBuilder
impl UnsafeUnpin for EthernetBuilder
impl UnwindSafe for EthernetBuilder
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