Documentation ¶
Index ¶
- func MapKeys[K comparable, V any](m map[K]V) []K
- func MapKeysVals[K comparable, V any](m map[K]V) ([]K, []V)
- func MapVals[K comparable, V any](m map[K]V) []V
- type Map
- func (l *Map[K, V]) Insert(k K, v V)
- func (l *Map[K, V]) Keys() *mylist.List[K]
- func (l *Map[K, V]) Len() int
- func (l *Map[K, V]) Range(f func(key K, value V))
- func (l *Map[K, V]) Remove(k K)
- func (l *Map[K, V]) RemoveKeys(listK []K)
- func (l *Map[K, V]) Reset(len int)
- func (l *Map[K, V]) ResetByMap(items map[K]V)
- func (l *Map[K, V]) Search(f func(key K, value V) bool)
- func (l *Map[K, V]) TakeAt(k K) (v V, b bool)
- func (l *Map[K, V]) ToArray() (allKeys []K, allValues []V)
- func (l *Map[K, V]) ToMap() map[K]V
- func (l *Map[K, V]) Value(k K) (v V, b bool)
- func (l *Map[K, V]) Values() *mylist.List[V]
- type MultiMap
- func (l *MultiMap[K, V]) HasKey(k K) bool
- func (l *MultiMap[K, V]) Insert(key K, value V)
- func (l *MultiMap[K, V]) Keys() *mylist.List[K]
- func (l *MultiMap[K, V]) Len() int
- func (l *MultiMap[K, V]) Range(f func(key K, value V))
- func (l *MultiMap[K, V]) RangeKey(key K, f func(index int, value V))
- func (l *MultiMap[K, V]) Remove(key K)
- func (l *MultiMap[K, V]) RemoveAtIndex(key K, index int)
- func (l *MultiMap[K, V]) Removes(key K)
- func (l *MultiMap[K, V]) Search(f func(key K, value V) bool)
- func (l *MultiMap[K, V]) SearchKey(key K, f func(index int, value V) bool)
- func (l *MultiMap[K, V]) TakeAt(k K) (v V, b bool)
- func (l *MultiMap[K, V]) Value(k K) (v V, b bool)
- func (l *MultiMap[K, V]) Values(key K) (values []V, b bool)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MapKeys ¶
func MapKeys[K comparable, V any](m map[K]V) []K
func MapKeysVals ¶
func MapKeysVals[K comparable, V any](m map[K]V) ([]K, []V)
func MapVals ¶
func MapVals[K comparable, V any](m map[K]V) []V
Types ¶
type Map ¶
type Map[K comparable, V any] struct { // contains filtered or unexported fields }
func NewMap ¶
func NewMap[K comparable, V any]() *Map[K, V]
func (*Map[K, V]) RemoveKeys ¶
func (l *Map[K, V]) RemoveKeys(listK []K)
func (*Map[K, V]) ResetByMap ¶
func (l *Map[K, V]) ResetByMap(items map[K]V)
type MultiMap ¶
type MultiMap[K comparable, V any] struct { // contains filtered or unexported fields }
func NewMultiMap ¶
func NewMultiMap[K comparable, V any]() *MultiMap[K, V]
func (*MultiMap[K, V]) RemoveAtIndex ¶
Click to show internal directories.
Click to hide internal directories.