pub struct PacketHeader {
pub version: u16,
pub flags: PacketFlags,
pub schema_hash: u64,
pub tick: u32,
pub baseline_tick: u32,
pub payload_len: u32,
}Expand description
Packet header (version 0).
This struct represents the header fields after the magic number. The magic number is validated separately during decoding and is not stored in this struct.
See WIRE_FORMAT.md for the complete specification.
Fields§
§version: u16Wire format version.
flags: PacketFlagsPacket flags.
schema_hash: u64Schema hash for compatibility checking.
tick: u32Simulation tick this snapshot represents.
baseline_tick: u32Baseline tick for delta packets (0 for full snapshots).
payload_len: u32Payload length in bytes.
Implementations§
Source§impl PacketHeader
impl PacketHeader
Trait Implementations§
Source§impl Clone for PacketHeader
impl Clone for PacketHeader
Source§fn clone(&self) -> PacketHeader
fn clone(&self) -> PacketHeader
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 PacketHeader
impl Debug for PacketHeader
Source§impl PartialEq for PacketHeader
impl PartialEq for PacketHeader
impl Copy for PacketHeader
impl Eq for PacketHeader
impl StructuralPartialEq for PacketHeader
Auto Trait Implementations§
impl Freeze for PacketHeader
impl RefUnwindSafe for PacketHeader
impl Send for PacketHeader
impl Sync for PacketHeader
impl Unpin for PacketHeader
impl UnwindSafe for PacketHeader
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