pub struct ControlPacket {
pub packet_id: u32,
pub message: ControlMessage,
}Expand description
Control packet for the reliable transport layer
Fields§
§packet_id: u32Packet ID for reliability
message: ControlMessageMessage content
Implementations§
Source§impl ControlPacket
impl ControlPacket
Sourcepub fn new(packet_id: u32, message: ControlMessage) -> Self
pub fn new(packet_id: u32, message: ControlMessage) -> Self
Create a new control packet
Trait Implementations§
Source§impl Clone for ControlPacket
impl Clone for ControlPacket
Source§fn clone(&self) -> ControlPacket
fn clone(&self) -> ControlPacket
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 moreAuto Trait Implementations§
impl !Freeze for ControlPacket
impl RefUnwindSafe for ControlPacket
impl Send for ControlPacket
impl Sync for ControlPacket
impl Unpin for ControlPacket
impl UnwindSafe for ControlPacket
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