Struct rtnetlink::RouteBuffer [−][src]
pub struct RouteBuffer<T> { /* fields omitted */ }
Methods
impl<T: AsRef<[u8]>> RouteBuffer<T>
[src]
impl<T: AsRef<[u8]>> RouteBuffer<T>
pub fn new(buffer: T) -> RouteBuffer<T>
[src]
pub fn new(buffer: T) -> RouteBuffer<T>
pub fn into_inner(self) -> T
[src]
pub fn into_inner(self) -> T
Consume the packet, returning the underlying buffer.
pub fn address_family(&self) -> u8
[src]
pub fn address_family(&self) -> u8
Return the address family field
pub fn destination_length(&self) -> u8
[src]
pub fn destination_length(&self) -> u8
Return the destination length field
pub fn source_length(&self) -> u8
[src]
pub fn source_length(&self) -> u8
Return the source length field
pub fn tos(&self) -> u8
[src]
pub fn tos(&self) -> u8
Return the tos field
pub fn table(&self) -> RouteTable
[src]
pub fn table(&self) -> RouteTable
Return the table id field
pub fn protocol(&self) -> RouteProtocol
[src]
pub fn protocol(&self) -> RouteProtocol
Return the routing protocol field
pub fn scope(&self) -> RouteScope
[src]
pub fn scope(&self) -> RouteScope
Return the scope field
pub fn kind(&self) -> RouteKind
[src]
pub fn kind(&self) -> RouteKind
Return the routie type field
pub fn flags(&self) -> RouteFlags
[src]
pub fn flags(&self) -> RouteFlags
Return the flags field
impl<'a, T: AsRef<[u8]> + ?Sized> RouteBuffer<&'a T>
[src]
impl<'a, T: AsRef<[u8]> + ?Sized> RouteBuffer<&'a T>
pub fn payload(&self) -> &'a [u8]
[src]
pub fn payload(&self) -> &'a [u8]
Return a pointer to the payload.
pub fn nlas(
&self
) -> impl Iterator<Item = Result<NlaBuffer<&'a [u8]>>>
[src]
pub fn nlas(
&self
) -> impl Iterator<Item = Result<NlaBuffer<&'a [u8]>>>
impl<'a, T: AsRef<[u8]> + AsMut<[u8]> + ?Sized> RouteBuffer<&'a mut T>
[src]
impl<'a, T: AsRef<[u8]> + AsMut<[u8]> + ?Sized> RouteBuffer<&'a mut T>
pub fn payload_mut(&mut self) -> &mut [u8]
[src]
pub fn payload_mut(&mut self) -> &mut [u8]
Return a mutable pointer to the payload.
impl<T: AsRef<[u8]> + AsMut<[u8]>> RouteBuffer<T>
[src]
impl<T: AsRef<[u8]> + AsMut<[u8]>> RouteBuffer<T>
pub fn set_address_family(&mut self, value: u8)
[src]
pub fn set_address_family(&mut self, value: u8)
Set the address family field
pub fn set_destination_length(&mut self, value: u8)
[src]
pub fn set_destination_length(&mut self, value: u8)
Set the destination length field
pub fn set_source_length(&mut self, value: u8)
[src]
pub fn set_source_length(&mut self, value: u8)
Set the source length field
pub fn set_tos(&mut self, value: u8)
[src]
pub fn set_tos(&mut self, value: u8)
Set the tos field
pub fn set_table(&mut self, value: RouteTable)
[src]
pub fn set_table(&mut self, value: RouteTable)
Set the table id field
pub fn set_protocol(&mut self, value: RouteProtocol)
[src]
pub fn set_protocol(&mut self, value: RouteProtocol)
Set the routing protocol field
pub fn set_scope(&mut self, value: RouteScope)
[src]
pub fn set_scope(&mut self, value: RouteScope)
Set the scope field
pub fn set_kind(&mut self, value: RouteKind)
[src]
pub fn set_kind(&mut self, value: RouteKind)
Set the routie type field
pub fn set_flags(&mut self, value: RouteFlags)
[src]
pub fn set_flags(&mut self, value: RouteFlags)
Set the flags field
Trait Implementations
impl<T: Debug> Debug for RouteBuffer<T>
[src]
impl<T: Debug> Debug for RouteBuffer<T>
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl<T: PartialEq> PartialEq for RouteBuffer<T>
[src]
impl<T: PartialEq> PartialEq for RouteBuffer<T>
fn eq(&self, other: &RouteBuffer<T>) -> bool
[src]
fn eq(&self, other: &RouteBuffer<T>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &RouteBuffer<T>) -> bool
[src]
fn ne(&self, other: &RouteBuffer<T>) -> bool
This method tests for !=
.
impl<T: Eq> Eq for RouteBuffer<T>
[src]
impl<T: Eq> Eq for RouteBuffer<T>
impl<T: Clone> Clone for RouteBuffer<T>
[src]
impl<T: Clone> Clone for RouteBuffer<T>
fn clone(&self) -> RouteBuffer<T>
[src]
fn clone(&self) -> RouteBuffer<T>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl<'a, T: AsRef<[u8]> + ?Sized> Parseable<RouteHeader> for RouteBuffer<&'a T>
[src]
impl<'a, T: AsRef<[u8]> + ?Sized> Parseable<RouteHeader> for RouteBuffer<&'a T>
fn parse(&self) -> Result<RouteHeader>
[src]
fn parse(&self) -> Result<RouteHeader>
Deserialize the current type.
impl<'buffer, T: AsRef<[u8]> + 'buffer> Parseable<RouteMessage> for RouteBuffer<&'buffer T>
[src]
impl<'buffer, T: AsRef<[u8]> + 'buffer> Parseable<RouteMessage> for RouteBuffer<&'buffer T>
fn parse(&self) -> Result<RouteMessage>
[src]
fn parse(&self) -> Result<RouteMessage>
Deserialize the current type.
impl<'buffer, T: AsRef<[u8]> + 'buffer> Parseable<Vec<RouteNla>> for RouteBuffer<&'buffer T>
[src]
impl<'buffer, T: AsRef<[u8]> + 'buffer> Parseable<Vec<RouteNla>> for RouteBuffer<&'buffer T>
Auto Trait Implementations
impl<T> Send for RouteBuffer<T> where
T: Send,
impl<T> Send for RouteBuffer<T> where
T: Send,
impl<T> Sync for RouteBuffer<T> where
T: Sync,
impl<T> Sync for RouteBuffer<T> where
T: Sync,