kv

package
v0.0.0-...-95df8b3 Latest Latest
Warning

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

Go to latest
Published: Oct 26, 2017 License: MIT Imports: 2 Imported by: 0

README

Result

go test -bench=. -benchtime=1s ./kv

PASS
BenchmarkKVCtx_Set-4           	 3000000	       419 ns/op
BenchmarkKVCtx_Get-4           	 3000000	       451 ns/op
BenchmarkKVChe_Set-4           	 5000000	       321 ns/op
BenchmarkKVChe_Get-4           	 5000000	       398 ns/op
BenchmarkKVChm_Set-4           	 5000000	       306 ns/op
BenchmarkKVChm_Get-4           	 5000000	       283 ns/op
BenchmarkKV_Set-4              	20000000	       116 ns/op
BenchmarkKV_Get-4              	10000000	       191 ns/op
BenchmarkKV_Channel_Set-4      	 2000000	       669 ns/op
BenchmarkKV_Channel_Get-4      	 2000000	       874 ns/op
BenchmarkKVR_Get-4             	20000000	        75.1 ns/op
BenchmarkMap_Successively_Set-4	 5000000	       438 ns/op
ok  	github.com/antonikonovalov/benches/kv	498.973s

Documentation

Index

Constants

This section is empty.

Variables

View Source
var KVChannelStore = NewKVC()
View Source
var KVCheStore = NewKVChe()
View Source
var KVChmStore = NewKVChm()
View Source
var KVCtxStore = NewKVCtx()
View Source
var KVRStore = &KVR{s: make(map[string]interface{}, 0)}
View Source
var KVStore = &KV{s: make(map[string]interface{}, 0)}

Functions

This section is empty.

Types

type KV

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

func (*KV) Get

func (k *KV) Get(key string) interface{}

func (*KV) Set

func (k *KV) Set(key string, val interface{})

type KVC

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

func NewKVC

func NewKVC() *KVC

func (*KVC) Get

func (k *KVC) Get(key string) interface{}

func (*KVC) Set

func (k *KVC) Set(key string, val interface{})

type KVChe

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

func NewKVChe

func NewKVChe() *KVChe

func (*KVChe) Get

func (kv *KVChe) Get(key string) interface{}

func (*KVChe) Set

func (kv *KVChe) Set(key string, val interface{})

type KVChm

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

func NewKVChm

func NewKVChm() *KVChm

func (*KVChm) Get

func (kv *KVChm) Get(key string) interface{}

func (*KVChm) Set

func (kv *KVChm) Set(key string, val interface{})

type KVCtx

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

func NewKVCtx

func NewKVCtx() *KVCtx

func (*KVCtx) Get

func (kv *KVCtx) Get(key string) interface{}

func (*KVCtx) Set

func (kv *KVCtx) Set(key string, val interface{})

type KVR

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

func (*KVR) Get

func (k *KVR) Get(key string) interface{}

func (*KVR) Set

func (k *KVR) Set(key string, val interface{})

Jump to

Keyboard shortcuts

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