[−][src]Struct pcap_parser::pcap::PcapHeader
PCAP global header
Fields
magic_number: u32File format and byte ordering. If equal to 0xa1b2c3d4 then the rest of
the file uses native byte ordering. If 0xd4c3b2a1 (swapped), then all
following fields will have to be swapped too.
version_major: u16Version major number (currently 2)
version_minor: u16Version minor number (currently 4)
thiszone: i32The correction time in seconds between GMT (UTC) and the local timezone of the following packet header timestamps
sigfigs: u32In theory, the accuracy of time stamps in the capture; in practice, all tools set it to 0
snaplen: u32max len of captured packets, in octets
network: LinktypeData link type
Methods
impl PcapHeader[src]
pub fn new() -> PcapHeader[src]
pub const fn size(&self) -> usize[src]
pub fn is_bigendian(&self) -> bool[src]
Trait Implementations
impl ToVec for PcapHeader[src]
fn to_vec_raw(&self) -> Result<Vec<u8>, GenError>[src]
fn to_vec(&mut self) -> Result<Vec<u8>, GenError>[src]
fn fix(&mut self)[src]
impl<'a> From<PcapHeader> for PcapBlockOwned<'a>[src]
fn from(b: PcapHeader) -> PcapBlockOwned<'a>[src]
impl<'a> From<&'a PcapHeader> for PcapBlock<'a>[src]
fn from(b: &'a PcapHeader) -> PcapBlock<'a>[src]
impl Clone for PcapHeader[src]
fn clone(&self) -> PcapHeader[src]
fn clone_from(&mut self, source: &Self)1.0.0[src]
impl Debug for PcapHeader[src]
Auto Trait Implementations
impl Send for PcapHeader
impl Sync for PcapHeader
impl Unpin for PcapHeader
impl RefUnwindSafe for PcapHeader
impl UnwindSafe for PcapHeader
Blanket Implementations
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.
fn to_owned(&self) -> T[src]
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.
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>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,