collection

package
v0.0.3 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Map

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

func NewMap

func NewMap[T any]() *Map[T]

func (*Map[T]) Delete

func (m *Map[T]) Delete(key string)

func (*Map[T]) Get

func (m *Map[T]) Get(key string) (val T, ok bool)

func (*Map[T]) GetAndUpdate

func (m *Map[T]) GetAndUpdate(key string, update func(old T, found bool) T) (val T)

func (*Map[T]) Len

func (s *Map[T]) Len() int

func (*Map[T]) Put

func (m *Map[T]) Put(key string, val T)

Jump to

Keyboard shortcuts

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