Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClientTmpl ¶
type ClientTmpl struct {
InitField map[string]string //初始化的成员字段
PackageName string //包名
ReceiverName string //接收器名
StructName string //结构体
AllFunc []Func //func
}
func (*ClientTmpl) Gen ¶
func (h *ClientTmpl) Gen(w io.Writer)
type Func ¶
type Func struct {
URL string //url 地址
URLTemplate bool //url 启用模板语法
Method string //http方法 GET POST DELETE之类的
DefReqHeader []model.KeyVal[string, string]
DefReqBody []model.KeyVal[string, string]
HaveHeader bool //有http header
HaveQuery bool //有查询字符串
HaveReqBody bool //有请求body
HaveRespBody bool //有请求body
ReqWWWForm bool //www form 编码
ReqName string //函数请求参数名
RespName string //函数响应参数名
HandlerName string //生成的函数名
}
Click to show internal directories.
Click to hide internal directories.