This is a creation in Article, where the information may have evolved or changed.
Read the Go Project source code, it is inconvenient to know what the interface is the implementation of the struct, very inconvenient.
List-interfaces This tool, used to analyze the Go Project source code, to help you quickly find out what the interface of the struct implementation.
List-interfaces use
list-interfaces --codedir /appdev/gopath/src/github.com/contiv/netplugin \--gopath /appdev/gopath \--outputfile /tmp/result参数说明--codedir 要分析的代码目录--gopath GOPATH环境变量目录--outputfile 分析结果保存到该文件
Sample output:
interface item 在文件/appdev/gopath/src/github.com/contiv/netplugin/vendor/google.golang.org/grpc/transport/transport.go中有2个struct实现了接口struct windowUpdate 在文件/appdev/gopath/src/github.com/contiv/netplugin/vendor/google.golang.org/grpc/transport/control.go中struct settings 在文件/appdev/gopath/src/github.com/contiv/netplugin/vendor/google.golang.org/grpc/transport/control.go中
Project Source Repository
Https://git.oschina.net/jscode/list-interfaces
Download Address
If your system is fedora25 x86_64 or a compatible system, you can download the compiled binary package.
Http://oog2gj1e8.bkt.clouddn.com/list-interfaces