hashtable

package
v0.0.0-...-0215403 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 24, 2020 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Hashtable

type Hashtable struct {
	// contains filtered or unexported fields
}

func NewHashTable

func NewHashTable(capacity int) *Hashtable

func (*Hashtable) Del

func (t *Hashtable) Del(k interface{})

Del a element from the matched list, but never delete the list if it existed.

func (*Hashtable) Get

func (t *Hashtable) Get(k interface{}) (v interface{})

Get a element. If can not match the key k, return nil.

func (*Hashtable) Set

func (t *Hashtable) Set(k, v interface{})

Set insert a new element or modify the existed one. New element always inserted at the front of list.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL