Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Hashmap ¶
type Hashmap interface { Put(key, val interface{}) Get(key interface{}) (val interface{}, exists bool) Delete(key interface{}) Len() int }
Hashmap provides an O(1) mapping from a comparable key to any value. Comparable is defined by https://golang.org/ref/spec#Comparison_operators.
type Iter ¶ added in v1.4.10
type Iter interface { Next() bool Key() interface{} Value() interface{} }
Iterates over the keys and values in a LinkedHashmap from oldest to newest elements. Assumes the underlying LinkedHashmap is not modified while the iterator is in use, except to delete elements that have already been iterated over.
type LinkedHashmap ¶
type LinkedHashmap interface { Hashmap Oldest() (val interface{}, exists bool) Newest() (val interface{}, exists bool) NewIterator() Iter }
LinkedHashmap is a hashmap that keeps track of the oldest pairing an the newest pairing.
func New ¶
func New() LinkedHashmap
Click to show internal directories.
Click to hide internal directories.