conmap

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2021 License: Apache-2.0 Imports: 4 Imported by: 0

README

This came about because I wanted to have concurrent maps but felt bad about casting out of them.

To re-generate the gen-conmaps.go with updates from conmaps.go:

go get github.com/justnoise/genny
cd $GOPATH/src/github.com/justnoise/genny
go install
cd $GOPATH/src/github.com/elotl/itzo/pkg/util/conmap
go generate

Note: Don't use github.com/cheekybits/genny for code generation. The original genny didn't handle many things well since it doesn't do real parsing (e.g. make([]NodeKeyTypeValueType when KeyType=string). So use the justnoise version of genny since it has been updated to parse the go source code.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type KeyType

type KeyType generic.Type

type KeyTypeValueType

type KeyTypeValueType struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func NewKeyTypeValueType

func NewKeyTypeValueType() *KeyTypeValueType

func (*KeyTypeValueType) Delete

func (m *KeyTypeValueType) Delete(key KeyType)

func (*KeyTypeValueType) Get

func (m *KeyTypeValueType) Get(key KeyType) ValueType

func (*KeyTypeValueType) GetOK

func (m *KeyTypeValueType) GetOK(key KeyType) (ValueType, bool)

func (*KeyTypeValueType) Items

func (*KeyTypeValueType) Len

func (m *KeyTypeValueType) Len() int

func (*KeyTypeValueType) Set

func (m *KeyTypeValueType) Set(key KeyType, value ValueType)

type NodeKeyTypeValueType

type NodeKeyTypeValueType struct {
	Key   KeyType
	Value ValueType
}

type NodeStringLogbufLogBuffer

type NodeStringLogbufLogBuffer struct {
	Key   string
	Value *logbuf.LogBuffer
}

type NodeStringOsProcess

type NodeStringOsProcess struct {
	Key   string
	Value *os.Process
}

type NodeStringString

type NodeStringString struct {
	Key   string
	Value string
}

type StringLogbufLogBuffer

type StringLogbufLogBuffer struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func NewStringLogbufLogBuffer

func NewStringLogbufLogBuffer() *StringLogbufLogBuffer

func (*StringLogbufLogBuffer) Delete

func (m *StringLogbufLogBuffer) Delete(key string)

func (*StringLogbufLogBuffer) Get

func (*StringLogbufLogBuffer) GetOK

func (m *StringLogbufLogBuffer) GetOK(key string) (*logbuf.LogBuffer, bool)

func (*StringLogbufLogBuffer) Items

func (*StringLogbufLogBuffer) Len

func (m *StringLogbufLogBuffer) Len() int

func (*StringLogbufLogBuffer) Set

func (m *StringLogbufLogBuffer) Set(key string, value *logbuf.LogBuffer)

type StringOsProcess

type StringOsProcess struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func NewStringOsProcess

func NewStringOsProcess() *StringOsProcess

func (*StringOsProcess) Delete

func (m *StringOsProcess) Delete(key string)

func (*StringOsProcess) Get

func (m *StringOsProcess) Get(key string) *os.Process

func (*StringOsProcess) GetOK

func (m *StringOsProcess) GetOK(key string) (*os.Process, bool)

func (*StringOsProcess) Items

func (m *StringOsProcess) Items() []NodeStringOsProcess

func (*StringOsProcess) Len

func (m *StringOsProcess) Len() int

func (*StringOsProcess) Set

func (m *StringOsProcess) Set(key string, value *os.Process)

type StringString

type StringString struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

func NewStringString

func NewStringString() *StringString

func (*StringString) Delete

func (m *StringString) Delete(key string)

func (*StringString) Get

func (m *StringString) Get(key string) string

func (*StringString) GetOK

func (m *StringString) GetOK(key string) (string, bool)

func (*StringString) Items

func (m *StringString) Items() []NodeStringString

func (*StringString) Len

func (m *StringString) Len() int

func (*StringString) Set

func (m *StringString) Set(key string, value string)

type ValueType

type ValueType generic.Type

Jump to

Keyboard shortcuts

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