conv

package
v0.0.0-...-5eee607 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2023 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IStringMap

func IStringMap(v interface{}) map[string]string

IStringMap converts v into a map[string]string, provided v is really a map[interface{}]interface{}. If not, returns an empty string map.

func IStringPairs

func IStringPairs(islice interface{}) [][]string

IStringPairs converts islice into a [][]string, where each element is a 2-pair []string. If islice is not a []interface{}, returns an empty [][]string

func IStringSlice

func IStringSlice(islice interface{}) []string

IStringSlice converts islice into a []string, provided islice is a []interface{}, or returns an empty slice if not.

func StringSliceSet

func StringSliceSet(slice []string) map[string]bool

StringSliceSet converts a []string into a map[string]bool where the keys in the map are values in the []string mapped to true.

Types

This section is empty.

Jump to

Keyboard shortcuts

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