Documentation ¶
Index ¶
- func Capitalize(str string) string
- func CopyStruct(src, dst interface{})
- func CopyStruct2(src, dst interface{})
- func DeepFields(ifaceType reflect.Type) []reflect.StructField
- func MapToStructWithOutType(src map[string]interface{}, dst interface{})
- func MapToStructWithOutTypeDeep(src map[string]interface{}, dst interface{}) interface{}
- func StructCopy(DstStructPtr interface{}, SrcStructPtr interface{})
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CopyStruct ¶
func CopyStruct(src, dst interface{})
func CopyStruct2 ¶
func CopyStruct2(src, dst interface{})
func DeepFields ¶
func DeepFields(ifaceType reflect.Type) []reflect.StructField
func MapToStructWithOutType ¶
func MapToStructWithOutType(src map[string]interface{}, dst interface{})
*
- Map转struct
- @param map 需要初始化的数据,key字段必须与实体类的成员名字一样,否则赋值为空
- @param entity 需要转化成的实体类
- @return
func MapToStructWithOutTypeDeep ¶
func MapToStructWithOutTypeDeep(src map[string]interface{}, dst interface{}) interface{}
//Map转struct(包含子struct)
func StructCopy ¶
func StructCopy(DstStructPtr interface{}, SrcStructPtr interface{})
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.