-
Notifications
You must be signed in to change notification settings - Fork 2
Requirements
Xun Gong edited this page Jul 29, 2019
·
12 revisions
go get -u -v github.com/fatih/color
一切以实物(具体代码)为准
-
interface.go
(Details can be seen in code)
type dhtNode interface {
Get(k string) (bool, string)
Put(k string, v string) bool
Del(k string) bool
Run()
Create()
Join(addr string) bool
Quit()
Ping(addr string) bool
}
userdef.go
func NewNode(port int) dhtNode {
// your code
}