Struct gnunet_sys::GNUNET_TUN_IPv4Header [−][src]
Standard IPv4 header.
Fields
_bitfield_1: __BindgenBitfieldUnit<[u8; 1], u8>
diff_serv: u8
total_length: u16
Length of the packet, including this header.
identification: u16
Unique random ID for matching up fragments.
_bitfield_2: __BindgenBitfieldUnit<[u8; 2], u16>
ttl: u8
How many more hops can this packet be forwarded?
protocol: u8
L4-protocol, for example, IPPROTO_UDP or IPPROTO_TCP.
checksum: u16
Checksum.
source_address: in_addr
Origin of the packet.
destination_address: in_addr
Destination of the packet.
Implementations
impl GNUNET_TUN_IPv4Header
[src]
pub fn header_length(&self) -> c_uint
[src]
pub fn set_header_length(&mut self, val: c_uint)
[src]
pub fn version(&self) -> c_uint
[src]
pub fn set_version(&mut self, val: c_uint)
[src]
pub fn new_bitfield_1(
header_length: c_uint,
version: c_uint
) -> __BindgenBitfieldUnit<[u8; 1], u8>
[src]
header_length: c_uint,
version: c_uint
) -> __BindgenBitfieldUnit<[u8; 1], u8>
pub fn flags(&self) -> c_uint
[src]
pub fn set_flags(&mut self, val: c_uint)
[src]
pub fn fragmentation_offset(&self) -> c_uint
[src]
pub fn set_fragmentation_offset(&mut self, val: c_uint)
[src]
pub fn new_bitfield_2(
flags: c_uint,
fragmentation_offset: c_uint
) -> __BindgenBitfieldUnit<[u8; 2], u16>
[src]
flags: c_uint,
fragmentation_offset: c_uint
) -> __BindgenBitfieldUnit<[u8; 2], u16>
Trait Implementations
impl Clone for GNUNET_TUN_IPv4Header
[src]
fn clone(&self) -> GNUNET_TUN_IPv4Header
[src]
pub fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Copy for GNUNET_TUN_IPv4Header
[src]
impl Debug for GNUNET_TUN_IPv4Header
[src]
Auto Trait Implementations
impl RefUnwindSafe for GNUNET_TUN_IPv4Header
impl Send for GNUNET_TUN_IPv4Header
impl Sync for GNUNET_TUN_IPv4Header
impl Unpin for GNUNET_TUN_IPv4Header
impl UnwindSafe for GNUNET_TUN_IPv4Header
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,
pub 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> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn clone_into(&self, target: &mut T)
[src]
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.
pub 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>,