common

package
v0.0.0-...-e5bbcc4 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2023 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 ConcurrentMap

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

func CreateConcurrentMap

func CreateConcurrentMap[K comparable, V any]() ConcurrentMap[K, V]

func (ConcurrentMap[K, V]) Delete

func (m ConcurrentMap[K, V]) Delete(k K) ConcurrentMap[K, V]

func (ConcurrentMap[K, V]) ForEach

func (m ConcurrentMap[K, V]) ForEach(traverse func(k K, v V)) ConcurrentMap[K, V]

func (ConcurrentMap[K, V]) Get

func (m ConcurrentMap[K, V]) Get(k K, d V) V

func (ConcurrentMap[K, V]) Set

func (m ConcurrentMap[K, V]) Set(k K, v V) ConcurrentMap[K, V]

func (ConcurrentMap[K, V]) Update

func (m ConcurrentMap[K, V]) Update(k K, update func(v V) V) ConcurrentMap[K, V]

func (ConcurrentMap[K, V]) Values

func (m ConcurrentMap[K, V]) Values() []V

type ConcurrentSet

type ConcurrentSet[T comparable] struct {
	// contains filtered or unexported fields
}

func CreateConcurrentSet

func CreateConcurrentSet[T comparable]() ConcurrentSet[T]

func (ConcurrentSet[T]) Add

func (s ConcurrentSet[T]) Add(key T)

func (ConcurrentSet[T]) AddUniq

func (s ConcurrentSet[T]) AddUniq(key T) bool

func (ConcurrentSet[T]) Has

func (s ConcurrentSet[T]) Has(key T) bool

func (ConcurrentSet[T]) Remove

func (s ConcurrentSet[T]) Remove(key T)

Jump to

Keyboard shortcuts

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