threadsafe

package
v0.0.0-...-d06b0b7 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2026 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handles

type Handles[T any, ID ~uintptr] struct {
	// contains filtered or unexported fields
}

func (*Handles[T, ID]) All

func (h *Handles[T, ID]) All(yield func(T) bool)

func (*Handles[T, ID]) Del

func (h *Handles[T, ID]) Del(handle ID)

func (*Handles[T, ID]) Get

func (h *Handles[T, ID]) Get(handle ID) T

func (*Handles[T, ID]) New

func (h *Handles[T, ID]) New(v T) ID

type Map

type Map[K comparable, V any] sync.Map

func (*Map[K, V]) Insert

func (m *Map[K, V]) Insert(key K, value V)

func (*Map[K, V]) Iter

func (m *Map[K, V]) Iter() iter.Seq2[K, V]

func (*Map[K, V]) Lookup

func (m *Map[K, V]) Lookup(key K) (value V, ok bool)

func (*Map[K, V]) Remove

func (m *Map[K, V]) Remove(key K)

type Queue

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

func (*Queue[T]) Pop

func (q *Queue[T]) Pop() (T, bool)

func (*Queue[T]) Push

func (q *Queue[T]) Push(v T)

type Slice

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

func (*Slice[T]) Append

func (slice *Slice[T]) Append(value T) int

func (*Slice[T]) Index

func (slice *Slice[T]) Index(index int) T

func (*Slice[T]) SetIndex

func (slice *Slice[T]) SetIndex(index int, value T)

func (*Slice[T]) Values

func (slice *Slice[T]) Values() iter.Seq2[int, T]

Jump to

Keyboard shortcuts

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