oop

package
v0.0.0-...-9a4132b Latest Latest
Warning

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

Go to latest
Published: Oct 29, 2024 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Chinese

type Chinese struct {
	// contains filtered or unexported fields
}

func (*Chinese) Speak

func (c *Chinese) Speak()

TODO: 通过定义接口中存在的方法,隐式的实现接口

type Human

type Human interface {
	Speak()
}

TODO: 通过接口的方式实现多态

type People

type People struct {
	// contains filtered or unexported fields
}

TODO: 声明结构体 实现封装

Jump to

Keyboard shortcuts

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