1 Star 0 Fork 0

nggs/micro

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
structure.go 726 Bytes
一键复制 编辑 原始数据 按行查看 历史
李文建 提交于 2020-04-05 00:11 +08:00 . 整合其他模块代码
package pbex
import (
"gitee.com/nggs/tools/pbplugin/golang"
"gitee.com/nggs/tools/pbplugin/golang/generator"
)
const (
PluginName = "pbex-go"
)
type message struct {
*golang.Message
Response string
}
func newMessage(g *generator.Generator, d *generator.Descriptor) *message {
m := &message{
Message: golang.NewMessage(g, d),
}
return m
}
type file struct {
*golang.File
Protocol string
Messages []*message
messagesByName map[string]*message
}
func newFile(fd *generator.FileDescriptor) *file {
f := &file{
File: golang.NewFile(fd),
messagesByName: map[string]*message{},
}
return f
}
func (f file) ProtocolTagFunctionName() string {
return generator.CamelCase(f.Protocol)
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Go
1
https://gitee.com/nggs/micro.git
git@gitee.com:nggs/micro.git
nggs
micro
micro
bac99dff65eb

搜索帮助