queue

package
v0.0.0-...-4d3d43f Latest Latest
Warning

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

Go to latest
Published: Mar 18, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CircleQueue

type CircleQueue struct {
	// contains filtered or unexported fields
}

func NewCircleQueue

func NewCircleQueue(size int) *CircleQueue

NewCircleQueue 如果是空队列,头尾指针都是-1

func (*CircleQueue) Clear

func (c *CircleQueue) Clear()

func (*CircleQueue) DeQueue

func (c *CircleQueue) DeQueue() any

DeQueue 出队列从头部出

func (*CircleQueue) Debug

func (c *CircleQueue) Debug() string

func (*CircleQueue) EnQueue

func (c *CircleQueue) EnQueue(item any) bool

EnQueue 入队列从尾部入

func (*CircleQueue) GetTail

func (c *CircleQueue) GetTail() any

func (*CircleQueue) IsEmpty

func (c *CircleQueue) IsEmpty() bool

func (*CircleQueue) IsFull

func (c *CircleQueue) IsFull() bool

func (*CircleQueue) Iter

func (c *CircleQueue) Iter() []any

Jump to

Keyboard shortcuts

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