server

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: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var HandlerTemplate string
View Source
var SvcTemplate string

Functions

func Gen

func Gen(m *MainTmpl, w io.Writer)

func GenConfig

func GenConfig(w io.Writer)

Types

type ConfigYAML

type ConfigYAML struct {
	GoModLastName string
}

func (*ConfigYAML) Gen

func (c *ConfigYAML) Gen(w io.Writer)

type HandlerTmpl

type HandlerTmpl struct {
	SubPackageName string
	GoMod          string
	Handler        string
	ReqName        string
	HasURL         bool
	HasHeader      bool
	HasQuery       bool
	HasJSONBody    bool
}

func (*HandlerTmpl) Gen

func (h *HandlerTmpl) Gen(w io.Writer)

type LogicTmpl

type LogicTmpl struct {
	SubPackageName string
	GoMod          string
	Handler        string
	ReqName        string
	RespName       string
}

func (*LogicTmpl) Gen

func (l *LogicTmpl) Gen(w io.Writer)

type MainTmpl

type MainTmpl struct {
	GoMod         string
	GoModLastName string
}

type Routes

type Routes struct {
	Method         string
	Path           string
	SubPackageName string
	Handler        string
}

type RoutesTmpl

type RoutesTmpl struct {
	AllRoute          []Routes
	GoMod             string
	AllSubPackageName []string
}

func (*RoutesTmpl) Gen

func (l *RoutesTmpl) Gen(w io.Writer)

type SvcTmpl

type SvcTmpl struct {
	GoMod string
}

func (*SvcTmpl) Gen

func (s *SvcTmpl) Gen(w io.Writer)

Jump to

Keyboard shortcuts

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