Reflect

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2024 License: GPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetField

func GetField(obj interface{}, name string) (i interface{}, err error)

func MakeValueType

func MakeValueType(ptr reflect.Type) reflect.Type

MakeValueType 将ptr类型的Type转换为val类型的Type

func SetField

func SetField(obj interface{}, name string, value interface{}) error

SetField 使用反射设置结构体字段的值,obj必须是个指针类型

Types

This section is empty.

Jump to

Keyboard shortcuts

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