Documentation ¶
Index ¶
- type Dict
- type HDict
- func (dict *HDict[Tk, Tv]) At(k Tk) Tv
- func (dict *HDict[Tk, Tv]) Clear()
- func (dict *HDict[Tk, Tv]) Del(keys ...Tk)
- func (dict *HDict[Tk, Tv]) Eq(other Dict[Tk, Tv], valuesEq func(vL, vR Tv) bool) bool
- func (dict *HDict[Tk, Tv]) Get(k Tk) (v Tv, ok bool)
- func (dict *HDict[Tk, Tv]) Insert(k Tk, v Tv) bool
- func (dict *HDict[Tk, Tv]) Items() Items[Tk, Tv]
- func (dict *HDict[Tk, Tv]) Iterate(f func(k Tk, v Tv) bool)
- func (dict *HDict[Tk, Tv]) Keys() []Tk
- func (dict *HDict[Tk, Tv]) Len() int
- func (dict *HDict[Tk, Tv]) Put(k Tk, v Tv)
- type HSet
- func (set *HSet) Clear()
- func (set *HSet) Contains(k T) bool
- func (set *HSet) Del(keys ...T)
- func (set *HSet) Eq(other Set[T]) bool
- func (set *HSet) Insert(k T) bool
- func (set *HSet) Iterate(f func(k T) bool)
- func (set *HSet) Len() int
- func (set *HSet) Put(k T)
- func (set *HSet) PutMany(vals ...T)
- func (set *HSet) Values() []T
- type Items
- type KV
- type RBDict
- func (dict *RBDict[Tk, Tv]) At(k Tk) Tv
- func (dict *RBDict[Tk, Tv]) Clear()
- func (dict *RBDict[Tk, Tv]) Del(keys ...Tk)
- func (dict *RBDict[Tk, Tv]) Eq(other Dict[Tk, Tv], valuesEq func(vL, vR Tv) bool) bool
- func (dict *RBDict[Tk, Tv]) Get(k Tk) (v Tv, ok bool)
- func (dict *RBDict[Tk, Tv]) Insert(k Tk, v Tv) bool
- func (dict *RBDict[Tk, Tv]) Items() Items[Tk, Tv]
- func (dict *RBDict[Tk, Tv]) Iterate(f func(k Tk, v Tv) bool)
- func (dict *RBDict[Tk, Tv]) Keys() []Tk
- func (dict *RBDict[Tk, Tv]) Len() int
- func (dict *RBDict[Tk, Tv]) Put(k Tk, v Tv)
- type RBSet
- func (set *RBSet) Clear()
- func (set *RBSet) Contains(k T) bool
- func (set *RBSet) Del(keys ...T)
- func (set *RBSet) Eq(other Set[T]) bool
- func (set *RBSet) Insert(k T) bool
- func (set *RBSet) Iterate(f func(k T) bool)
- func (set *RBSet) Len() int
- func (set *RBSet) Put(k T)
- func (set *RBSet) PutMany(vals ...T)
- func (set *RBSet) Values() []T
- type Set
- type StringCiKey
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Dict ¶
type Dict[Tk any, Tv any] interface { Clear() Len() int Del(keys ...Tk) Put(k Tk, v Tv) Insert(k Tk, v Tv) bool Get(k Tk) (v Tv, ok bool) Keys() []Tk Items() Items[Tk, Tv] Iterate(f func(k Tk, v Tv) bool) At(k Tk) Tv Eq(other Dict[Tk, Tv], valuesEq func(vL, vR Tv) bool) bool }
Dict abstact interface
type HDict ¶
type HDict[Tk comparable, Tv any] struct { // contains filtered or unexported fields }
HDict hashed dictionary
type HSet ¶
type HSet[T comparable] struct { // contains filtered or unexported fields }
type RBDict ¶
RBDict red-black tree; type key 'Tk' should be Ordered or cmpOps[Tk] interface
type Set ¶
type Set[T any] interface { Clear() Len() int Del(keys ...T) Put(k T) PutMany(vals ...T) Insert(k T) bool Contains(k T) bool Iterate(f func(k T) bool) Values() []T Eq(Set[T]) bool }
Set -
Click to show internal directories.
Click to hide internal directories.