Documentation
¶
Index ¶
- type Map
- func (m *Map[K, V]) Contains(key K) bool
- func (m *Map[K, V]) Del(key K) bool
- func (m *Map[K, V]) Get(key K) (V, bool)
- func (m *Map[K, V]) Items() iter.Seq2[K, *V]
- func (m *Map[K, V]) Keys() []K
- func (m *Map[K, V]) Len() int
- func (m *Map[K, V]) MarshalJSON() ([]byte, error)
- func (m *Map[K, V]) Put(key K, value V) bool
- func (m *Map[K, V]) Vals() []V
- type Set
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Map ¶
A sorted map implementation. Keeps keys and values in separate arrays, to improve memory locality when searching through the key space.
func (*Map[K, V]) Get ¶
Returns the value in the map, if found and an indicator whether found or not. If not found the value will be the 0-value
func (*Map[K, V]) MarshalJSON ¶
Custom JSON marshalling, to make its use transparent with Go's json package.
type Set ¶
A sorted set implementation. Keeps keys in a sorted vector to improve memory locality.
func (*Set[T]) MarshalJSON ¶
Custom JSON marshalling, to make its use transparent with Go's json package.
func (*Set[T]) UnmarshalJSON ¶
Custom JSON marshalling, to make its use transparent with Go's json package.
Click to show internal directories.
Click to hide internal directories.