Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FIFO ¶
FIFO is a simple queue designed to queue packets. It can also be used as a freelist using the PopOrCreate function
func New ¶
New creates the FIFO. All allocations will be a multiple of allocSize to reduce the need to reallocate
func (*FIFO) Pop ¶
Pop removes and returns the first element of the FIFO. It there is no element nil is returned
func (*FIFO) Reallocate ¶
func (b *FIFO) Reallocate()
Reallocate reallocates the internal ring buffer. This can be used to free some memory after an episode of heavy load.
Click to show internal directories.
Click to hide internal directories.