modeltemplate

package
v0.0.0-...-d37067d Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2021 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ModelMethodTemplate

type ModelMethodTemplate struct {
	PackageName       string
	ModelName         string
	ModelVariableName string
	Method            methodtemplate.MethodTemplate
	// contains filtered or unexported fields
}

func NewImplementorMethodTemplates

func NewImplementorMethodTemplates(pkgName, implName string, method methodtemplate.MethodTemplate, path string) *ModelMethodTemplate

func (*ModelMethodTemplate) GenerateFile

func (t *ModelMethodTemplate) GenerateFile(fileMgr *filemanager.FileManager)

type Template

type Template struct {
	PackageName        string
	ModelName          string
	NewFuncName        string
	Imports            []string
	Attributes         []string
	NewFuncParameters  string
	VariableParameters []string
	Methods            []models.Method
	// contains filtered or unexported fields
}

func NewTemplate

func NewTemplate(pkgName string, m models.Model, path string) *Template

func (*Template) GenerateFile

func (t *Template) GenerateFile(fileMgr *filemanager.FileManager)

Jump to

Keyboard shortcuts

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