Struct PacketsQueue
A queue of packets with an internal pool of preallocated packet buffers.
Implements
Inherited Members
Namespace: Unity.Networking.Transport
Assembly: solution.dll
Syntax
public struct PacketsQueue : IDisposable
Properties
Name | Description |
---|---|
Capacity | Total capacity of the queue. |
Count | Number of packets currently in the queue. |
IsCreated | Whether the queue has been created or not. |
this[int] | Gets the packet processor for the packet at the given index. |
Methods
Name | Description |
---|---|
Clear() | Removes and releases all the packets in the queue. |
Dispose() | Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources. |
EnqueuePacket(out PacketProcessor) | Acquires a new packet buffer from the packets pool if there are any available. |
EnqueuePackets(ref PacketsQueue) | Copies all the packets from the given queue into this one. Note that no error is raised if not all packets could be copied. It is the responsibility of the caller to ensure that the queue can fit all the packets from the given queue. |