Documentation ¶
Index ¶
- type Hashtable_t
- func (ht *Hashtable_t) Del(key interface{})
- func (ht *Hashtable_t) Elems() []Pair_t
- func (ht *Hashtable_t) Get(key interface{}) (interface{}, bool)
- func (ht *Hashtable_t) GetRLock(key interface{}) (interface{}, bool)
- func (ht *Hashtable_t) Iter(f func(interface{}, interface{}) bool) bool
- func (ht *Hashtable_t) Set(key interface{}, value interface{}) (interface{}, bool)
- func (ht *Hashtable_t) Size() int
- func (ht *Hashtable_t) String() string
- type Pair_t
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Hashtable_t ¶
type Hashtable_t struct {
// contains filtered or unexported fields
}
func MkHash ¶
func MkHash(size int) *Hashtable_t
func (*Hashtable_t) Del ¶
func (ht *Hashtable_t) Del(key interface{})
returns true if the key was removed
func (*Hashtable_t) Elems ¶
func (ht *Hashtable_t) Elems() []Pair_t
func (*Hashtable_t) Get ¶
func (ht *Hashtable_t) Get(key interface{}) (interface{}, bool)
func (*Hashtable_t) GetRLock ¶
func (ht *Hashtable_t) GetRLock(key interface{}) (interface{}, bool)
For performance comparisons
func (*Hashtable_t) Iter ¶
func (ht *Hashtable_t) Iter(f func(interface{}, interface{}) bool) bool
Returns true if at least one call to f returned true. stops iterating once f returns true.
func (*Hashtable_t) Set ¶
func (ht *Hashtable_t) Set(key interface{}, value interface{}) (interface{}, bool)
Set returns false if key already exists
func (*Hashtable_t) Size ¶
func (ht *Hashtable_t) Size() int
func (*Hashtable_t) String ¶
func (ht *Hashtable_t) String() string
Click to show internal directories.
Click to hide internal directories.