collections

package
v1.10.0 Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2026 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 MinHeap

type MinHeap[K any, V comparable] struct {
	// contains filtered or unexported fields
}

func NewMinHeap

func NewMinHeap[K any, V comparable](less func(a, b K) bool) *MinHeap[K, V]

func (*MinHeap[K, V]) Len

func (h *MinHeap[K, V]) Len() int

func (*MinHeap[K, V]) Peek

func (h *MinHeap[K, V]) Peek() (K, V, bool)

func (*MinHeap[K, V]) Pop

func (h *MinHeap[K, V]) Pop() (K, V, bool)

func (*MinHeap[K, V]) Push

func (h *MinHeap[K, V]) Push(key K, value V)

func (*MinHeap[K, V]) RemoveByValue

func (h *MinHeap[K, V]) RemoveByValue(value V) bool

type RingBuffer

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

func NewRingBuffer

func NewRingBuffer[T any](initialCap int) *RingBuffer[T]

func (*RingBuffer[T]) Len

func (rb *RingBuffer[T]) Len() int

func (*RingBuffer[T]) Pop

func (rb *RingBuffer[T]) Pop() (T, bool)

func (*RingBuffer[T]) Push

func (rb *RingBuffer[T]) Push(item T)

Jump to

Keyboard shortcuts

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