pyaml

package
v0.1.7 Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2023 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetBody added in v0.0.4

func GetBody(h model.Multi, isProtobuf bool) (reqBody Body, defReqBody []model.KeyVal[string, string], respBody Body, err error)

func GetHeader added in v0.0.4

func GetHeader(h model.Multi, opt ...option.OptionFunc) (reqHeader Header, defReqHeader []model.KeyVal[string, string],
	respHeader Header, defRespHeader []model.KeyVal[string, string], err error)

func Parse

func Parse(fileName string) (c *model.Config, err error)

Types

type Body added in v0.0.4

type Body struct {
	Name       string
	StructType string
}
type Header struct {
	Name       string
	StructType string
}

type Query added in v0.0.4

type Query struct {
	Name       string
	StructType string
}

type Req added in v0.0.4

type Req struct {
	Name   string //请求的结构体名
	Query  Query  //Query string 名
	Body   Body   //body名
	Header Header //header名
}

type ReqResp added in v0.0.4

type ReqResp struct {
	Req  Req  //请求
	Resp Resp //响应
}

type Resp added in v0.0.4

type Resp struct {
	Name   string
	Body   Body   //响应body结构体名
	Header Header //响应header结构体名
}

type TypeTmpl added in v0.0.4

type TypeTmpl struct {
	PackageName string
	ReqResp     []ReqResp
}

Jump to

Keyboard shortcuts

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