package
Version:
v0.1.2
Opens a new window with list of versions in this module.
Published: Dec 28, 2024
License: Apache-2.0
Opens a new window with license information.
Imports: 1
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
¶
type CMaper[K comparable, V any] interface {
Delete(key K)
Load(key K) (value V, ok bool)
LoadAndDelete(key K) (value V, loaded bool)
LoadOrStore(key K, value V) (actual V, loaded bool)
Range(f func(key K, value V) bool)
Store(key K, value V)
}
type Map[K constraints.Ordered, V any] interface {
Get(k K) (elem V)
TryGet(k K) (elem V, ok bool)
Delete(k K)
Set(k K, v V)
Swap(k K, v V) (prev V, replaced bool)
Len() int
Range(callback func(k K, v V) bool)
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.