reflect

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Feb 7, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CopyObj

func CopyObj(from interface{}, to interface{}, fields []string) (changed bool, err error)

func CopyObjViaYaml

func CopyObjViaYaml(to interface{}, from interface{}) error

CopyObjViaYaml marshal "from" to yaml data, then unMarshal data to "to".

func GetObjFieldsMap

func GetObjFieldsMap(obj interface{}, fields []string) map[string]interface{}

func StructName

func StructName(obj interface{}) string

StructName used to get the struct name from the obj.

func ToGormDBMap

func ToGormDBMap(obj interface{}, fields []string) (map[string]interface{}, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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