queue

package
v1.31.0-alpha.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 2, 2024 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type FIFO

type FIFO[T any] struct {
	// contains filtered or unexported fields
}

FIFO implements a first-in-first-out queue with unbounded size. The null FIFO is a valid empty queue.

Access must be protected by the caller when used concurrently by different goroutines, the queue itself implements no locking.

func (*FIFO[T]) Len

func (q *FIFO[T]) Len() int

func (*FIFO[T]) Pop

func (q *FIFO[T]) Pop() (element T, ok bool)

func (*FIFO[T]) Push

func (q *FIFO[T]) Push(element T)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL