util

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Apr 15, 2024 License: MPL-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetUserInput

func GetUserInput(asking string, masked bool) (userInput string, err error)

func SetStructField

func SetStructField(obj any, key string, value string) (bool, error)

Set arbitrary struct field.

func ToMap

func ToMap(in interface{}, tag string) (map[string]interface{}, error)

func ToTagFieldNameMap

func ToTagFieldNameMap(obj any, tag string, tagNum int) (map[string]string, error)

Return map[tag]FieldName of a given struct. TODO: Add check if tag is not set.

Types

This section is empty.

Jump to

Keyboard shortcuts

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