[][src]Struct enet_sys::_ENetPacket

#[repr(C)]
pub struct _ENetPacket { pub referenceCount: usize, pub flags: enet_uint32, pub data: *mut enet_uint8, pub dataLength: usize, pub freeCallback: ENetPacketFreeCallback, pub userData: *mut c_void, }

ENet packet structure.

An ENet data packet that may be sent to or received from a peer. The shown fields should only be read and never modified. The data field contains the allocated data for the packet. The dataLength fields specifies the length of the allocated data. The flags field is either 0 (specifying no flags), or a bitwise-or of any combination of the following flags:

ENET_PACKET_FLAG_RELIABLE - packet must be received by the target peer and resend attempts should be made until the packet is delivered

ENET_PACKET_FLAG_UNSEQUENCED - packet will not be sequenced with other packets (not supported for reliable packets)

ENET_PACKET_FLAG_NO_ALLOCATE - packet will not allocate data, and user must supply it instead

@sa ENetPacketFlag

Fields

referenceCount: usize

< internal use only

flags: enet_uint32

< bitwise-or of ENetPacketFlag constants

data: *mut enet_uint8

< allocated data for packet

dataLength: usize

< length of data

freeCallback: ENetPacketFreeCallback

< function to be called when the packet is no longer in use

userData: *mut c_void

< application private data, may be freely modified

Trait Implementations

impl Copy for _ENetPacket[src]

impl Clone for _ENetPacket[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl !Send for _ENetPacket

impl !Sync for _ENetPacket

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.