TODO: 完善剩下来的内容

This commit is contained in:
huangsimin
2019-10-08 18:22:24 +08:00
parent 037fe62588
commit d5f413c9e9
3 changed files with 165 additions and 121 deletions

View File

@@ -38,26 +38,61 @@ func DoFunc(a func(
// ExStruct 升级
type ExStruct struct {
ChildStruct struct {
A int
B interface{}
A int
B interface{}
girl string
boy int
}
C string
D func(a int, b string)
C string
D func(a int, b string)
child string
}
// GetChildStructBoy Get return boy int
func (es *ExStruct) GetChildStructBoy() int {
return es.ChildStruct.boy
}
// SetChildStructBoy Set boy int
func (es *ExStruct) SetChildStructBoy(boy int) {
es.ChildStruct.boy = boy
}
// GetChildStructGirl Get return girl string
func (es *ExStruct) GetChildStructGirl() string {
return es.ChildStruct.girl
}
// SetChildStructGirl Set girl string
func (es *ExStruct) SetChildStructGirl(girl string) {
es.ChildStruct.girl = girl
}
// GetChildStructGirl
// GetChildStructB Get return B interface{}
func (es *ExStruct) GetChildStructB() interface{} {
return es.ChildStruct.B
}
// SetChildStructB Set B interface{}
func (es *ExStruct) SetChildStructB(B interface{}) {
es.ChildStruct.B = B
}
// SetChildStructA set
func (e *ExStruct) SetChildStructA(a int) {
e.ChildStruct.A = a
func (es *ExStruct) SetChildStructA(a int) {
es.ChildStruct.A = a
}
// GetChildStructA get
func (e *ExStruct) GetChildStructA(a int) {
e.ChildStruct.A = a
func (es *ExStruct) GetChildStructA() int {
return es.ChildStruct.A
}
// GetC get
func (e *ExStruct) GetC(a int) {
e.ChildStruct.A = a
func (es *ExStruct) GetC(a int) {
es.ChildStruct.A = a
}
func main() {