internal

package
v0.1.2 Latest Latest
Warning

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

Go to latest
Published: Dec 8, 2021 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseFiles

func ParseFiles(files []string) ([]*ast.File, error)

ParseFiles parses the files to get AST.

func ParsePackage

func ParsePackage(dirPattern []string) (*packages.Package, error)

ParsePackage parses files according to given directory pattern to get the package information.

Types

type Field

type Field struct {
	// FieldName is a name of the field.
	FieldName string
	// FieldType is a type of the field.
	FieldType string
	// ParamName is a query parameter's name
	ParamName string

	TimeFormatterStmt g.Statement
}

Field represents a field of the structure for a constructor to be generated.

func CollectQueryParameterFieldsFromAST

func CollectQueryParameterFieldsFromAST(typeName string, astFiles []*ast.File) ([]*Field, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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