Help us shape the future of Go! Take the 2026 Go Developer Survey

mapx

package
v0.0.11 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Env

type Env struct {
	*EnvMap
}

func NewEnv

func NewEnv(m *EnvMap) *Env

func (*Env) AsEnviron

func (e *Env) AsEnviron() []string

func (*Env) Expand

func (e *Env) Expand(s string) (string, error)

func (*Env) GetOrEnv

func (e *Env) GetOrEnv(key string) string

type EnvMap

type EnvMap = Map[string, string]

type Map

type Map[K comparable, V any] struct {
	// contains filtered or unexported fields
}

Wrapped map[K]V; safe for concurrent use.

func NewMap

func NewMap[K comparable, V any](m map[K]V) *Map[K, V]

func (*Map[K, V]) Clone

func (m *Map[K, V]) Clone() *Map[K, V]

func (*Map[K, V]) Delete

func (m *Map[K, V]) Delete(key K)

func (*Map[K, V]) Get

func (m *Map[K, V]) Get(key K) (V, bool)

func (*Map[K, V]) Keys

func (m *Map[K, V]) Keys() []K

func (*Map[K, V]) Len

func (m *Map[K, V]) Len() int

func (*Map[K, V]) MarshalJSON

func (m *Map[K, V]) MarshalJSON() ([]byte, error)

func (*Map[K, V]) Merge

func (m *Map[K, V]) Merge(other *Map[K, V])

func (*Map[K, V]) Set

func (m *Map[K, V]) Set(key K, value V)

func (*Map[K, V]) UnmarshalJSON

func (m *Map[K, V]) UnmarshalJSON(b []byte) error

func (*Map[K, V]) Unwrap

func (m *Map[K, V]) Unwrap() map[K]V

Unwrap returns a cloned internal map.

Jump to

Keyboard shortcuts

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