pub struct TcpHeader(/* private fields */);
Implementations§
source§impl TcpHeader
impl TcpHeader
pub fn with_bytes(bytes: Bytes) -> Result<(TcpHeader, Bytes)>
pub fn max_len() -> usize
pub fn len(&self) -> usize
pub fn src(&self) -> u16
pub fn dest(&self) -> u16
pub fn seq_num(&self) -> u32
pub fn ack_num(&self) -> u32
pub fn is_syn(&self) -> bool
pub fn is_ack(&self) -> bool
pub fn is_fin(&self) -> bool
pub fn checksum_valid<V: Iterator<Item = u16>>( &self, header: &IpHeader, data: V ) -> bool
pub fn calculated_checksum<V: Iterator<Item = u16>>( &self, header: &IpHeader, data: V ) -> u16
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TcpHeader
impl !RefUnwindSafe for TcpHeader
impl !Send for TcpHeader
impl !Sync for TcpHeader
impl Unpin for TcpHeader
impl !UnwindSafe for TcpHeader
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