An open API service indexing awesome lists of open source software.

https://github.com/rocket049/gostructcopy

copy the exported value of a struct to a likely struct , with reflect.
https://github.com/rocket049/gostructcopy

Last synced: 6 months ago
JSON representation

copy the exported value of a struct to a likely struct , with reflect.

Awesome Lists containing this project

README

          

# gostructcopy
func:
```
//CopyToStruct copy the exported value of a struct to a likely struct , with reflect.利用 reflect 技术把结构体的可 export 值复制到 dst 中
func StructCopy(src, dst interface{}) error
```

copy the exported value of a struct to a likely struct , with reflect. dst must be pointer to s likely struct.

利用 reflect 技术把结构体的可 export 值复制到 dst 中,dst 必须是相似结构体的指针。