types

package
v0.0.2 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2022 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewExampleData

func NewExampleData(kind string) string

Types

type ContactInfo

type ContactInfo struct {
	Name  string `json:"name,omitempty"`
	URL   string `json:"url,omitempty"`
	Email string `json:"email,omitempty"`
}

type DocInfo

type DocInfo struct {
	ID       string
	Info     *Info
	Host     string `json:"host,omitempty"`
	BasePath string `json:"basePath,omitempty"`
}

type ErrorDes

type ErrorDes struct {
	Code     int    `json:"code"`
	Msg      string `json:"msg"`
	Describe string `json:"describe"`
}

type Info

type Info struct {
	Description    string       `json:"description,omitempty"`
	Title          string       `json:"title,omitempty"`
	TermsOfService string       `json:"termsOfService,omitempty"`
	Contact        *ContactInfo `json:"contact,omitempty"`
	Version        string       `json:"version,omitempty"`
}

type Method

type Method struct {
	Title        string        `json:"title"`
	Name         string        `json:"name"`
	Describe     string        `json:"describe"`
	IsSubscribe  bool          `json:"is_Subscribe"`
	Input        []*ParamField `json:"input"`
	OutPut       []*ParamField `json:"out_put"`
	RequestBody  string        `json:"request_body"`
	ResponseBody string        `json:"response_body"`
}

type MethodItem

type MethodItem struct {
	ID          string   `json:"operationId,omitempty"`
	Description string   `json:"description,omitempty"`
	Tags        []string `json:"tags,omitempty"`
}

type Module

type Module struct {
	NameSpace string    `json:"name_space"`
	Version   string    `json:"version"`
	PkgPath   string    `json:"pkg_path"`
	Name      string    `json:"name"`
	Methods   []*Method `json:"methods"`
	Describe  string    `json:"describe"`
}

type ParamData

type ParamData struct {
	Name     string        `json:"name"`
	Describe string        `json:"describe"`
	PkgPath  string        `json:"pkg_path"`
	Fields   []*ParamField `json:"fields"`
}

type ParamField

type ParamField struct {
	Name     string `json:"name"`
	Obj      bool   `json:"obj"`
	Type     string `json:"type"`
	DataType string `json:"data_type"`
	Example  string `json:"example"`
	Describe string `json:"describe"`
}

func (*ParamField) SetParamField

func (p *ParamField) SetParamField()

type Server

type Server struct {
	ServiceName string       `json:"service_name"`
	Links       []string     `json:"links"`
	Modules     []*Module    `json:"modules"`
	ParamDatas  []*ParamData `json:"param_datas"`
	ErrorCodes  []*ErrorDes  `json:"error_codes"`
}

Jump to

Keyboard shortcuts

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