queue

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2023 License: GPL-3.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 PQueue

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

func NewPriority

func NewPriority[T any](compare func(T, T) bool) PQueue[T]

func (PQueue[T]) Bottom

func (self PQueue[T]) Bottom() T

func (PQueue[T]) Empty

func (self PQueue[T]) Empty() bool

func (*PQueue[T]) Pop

func (self *PQueue[T]) Pop() T

func (*PQueue[T]) Push

func (self *PQueue[T]) Push(items ...T)

func (PQueue[T]) Size

func (self PQueue[T]) Size() int

func (PQueue[T]) Top

func (self PQueue[T]) Top() T

type Queue

type Queue[T any] []T

func New

func New[T any](items ...T) Queue[T]

func (Queue[T]) Bottom

func (self Queue[T]) Bottom() T

func (Queue[T]) Empty

func (self Queue[T]) Empty() bool

func (*Queue[T]) Pop

func (self *Queue[T]) Pop() T

func (*Queue[T]) Push

func (self *Queue[T]) Push(items ...T)

func (Queue[T]) Size

func (self Queue[T]) Size() int

func (Queue[T]) Top

func (self Queue[T]) Top() T

Jump to

Keyboard shortcuts

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